configuration
ما الذي تفعله
تخزن هذه المهارة قيم إعدادات مُسماة بمخطط يتحقق من كل قيمة، فيقرأ العمال في نظامك الإعدادات نفسها من مكان واحد. وهي موجهة للمطورين الذين يبنون أنظمة قائمة على iii ويحتاجون إلى إعدادات مشتركة ومُتحقَّق منها.
متى تستخدمها
- ✓عندما يحتاج عدة عمال إلى الاتفاق على الإعدادات نفسها دون مسارات ملفات مكتوبة في الكود.
- ✓عندما تريد التحقق من قيمة إعداد بمخطط قبل استخدامها.
- ✓عندما تريد أن يتفاعل عامل مع تغيير إعداد دون استطلاع دوري.
رابط المهارة
https://github.com/iii-hq/iii/blob/main/engine/src/workers/configuration/skills/SKILL.mdانسخه والصقه في الذكاء الاصطناعي الذي تستخدمه (Claude أو ChatGPT أو Cursor) واطلب منه اتباع التعليمات.
طريقة الاستخدام
أسهل طريقة: انسخ الرسالة والصقها في الذكاء الاصطناعي الذي تستخدمه. سيقرأ المهارة وينفّذ تعليماتها.
رسالة جاهزة للصق
لـ Claude Code أو Codex أو Cursor: شغّله داخل مجلد مشروعك وستُثبَّت المهارة.
نزّل ملف SKILL.md وضعه في مجلد مهارات وكيلك.
مثال على ما تطلبه من الذكاء الاصطناعي
“اضبط إدخال إعدادات مشتركاً لخدمة الفوترة عندي، مع مخطط يتحقق من قيمه.”
5 مهارات جديدة كل أسبوع. قراءة في دقيقة واحدة.
كيف تعمل
يسجّل كل عامل مخطط إعداداته مرة واحدة عند بدء التشغيل، ثم ينشر قيمه. يقرأ العمال الآخرون هذه القيم، ويُطلَق محفّز مربوط عند تغيّر أي قيمة. والتخزين الافتراضي يحتفظ بملف YAML واحد لكل إدخال.
المحتوى التقني (ملف SKILL.md الأصلي)
النص الأصلي من المؤلف، مباشرة من GitHub.
configuration
The configuration worker is a server-side registry of named entries. Every entry has an id (e.g. iii-stream, billing-service), a human-readable name and description, a JSON Schema describing the value shape, and a JSON value validated against that schema. Workers call configuration::register once at startup to declare their schema and configuration::set to publish values; consumers call configuration::get / configuration::list to read and bind a configuration trigger to react to changes without polling.
The default fs adapter persists one YAML file per id under ./config and watches the directory for external edits, so manual edits surface as configuration:updated events. The bridge adapter delegates to a remote engine. The worker is engine-owned and may be configured at engine.workers.configuration.
A per-id TTL (off by default) cleans up entries whose last subscriber trigger has unregistered, scoped to the lifecycle of ephemeral workers that come and go without an explicit teardown step.
When to Use
- A worker needs a typed, observable configuration surface other workers can read and validate against.
- Two workers need to agree on the same configuration values without one polling the other or hardcoding a path on disk.
- An operator should be able to edit a single YAML file (or the remote control plane) and have the change propagate to every subscriber without a worker restart.
- A worker comes and goes (sandboxes, ephemeral consumers) and its configuration should be cleaned up automatically when no one is left subscribing.
Boundaries
- Not a general-purpose key/value store — every entry must have a registered JSON Schema. Use the standalone
stateworker for free-form values. - No partial-update surface;
setalways replaces the whole value. Build the new value client-side and ship it in one call. - The
bridgeadapter cannot delete entries on the remote engine; cleanup over the bridge happens via TTL or directly on the source engine. - Over the
bridgeadapter,configuration::ensureis decided by the remote engine (the original candidate is forwarded there), so it requires a remote engine that exposesconfiguration::ensure; against an older remote it fails closed withADAPTER_ERRORrather than falling back to an unsaferegister. - Schemas are not version-checked across re-registrations — re-registering with an incompatible schema simply replaces it. Coordinate schema migrations out-of-band.
Migration and runtime overrides
Compose defaults to <namespace>-<container-key> without a hash (for example,
default-harness). Invalid or over-64-character generated names require explicit config_name.
Compose migrates only the exact previous namespace/key hash before starting a stopped worker.
After hashed migration, only the default namespace adopts the exact bare container key,
unless another container explicitly owns it. The bare source wins over an existing destination;
configuration::migrate is the single operation, delegated through bridges to the authority.
It returns { action, entry } with migrated, preserved (existing destination with absent
source, or matching IDs with an existing entry), or missing (both source and destination absent).
Before migration, Compose and every bridge hop query the read-only
configuration::migration-capabilities and require source_priority_archive_revision: 1.
Unknown or unavailable capabilities fail closed before invoking migration; upgrade the authority.
It replaces the destination with the raw source entry, then archives the original source as
<source>.yaml.bak. The previous destination is not backed up. .yaml.bak, .bak.yaml, and
.bkup.yaml files are ignored during loading, watching and legacy directory migration.
An existing identical backup permits cleanup recovery; a conflicting backup is never overwritten.
Missing source is a no-write no-op. Unsupported adapters fail closed.
Stop source consumers before migrating; do not share an fs directory between engine processes.
config_override is delivered through the existing service API. Compose reads the
current configuration with configuration::get (raw: true), merges defaults and
overrides, then calls configuration::set with flush: false before starting the
worker. No snapshot file is delivered. III_CONFIG_NAME identifies the entry.
Memory-only updates never write persistent config/<id>.yaml, and no delayed flush
is sched
الأسئلة الشائعة
أين تُخزَّن القيم؟
افتراضياً يُحفظ كل إدخال في ملف YAML واحد داخل مجلد إعدادات، ويمكنك تعديله مباشرة أيضاً.
هل يمكن التقاط التغيير دون إعادة تشغيل؟
نعم. يُطلَق محفّز عند تحديث الإدخال، فيتفاعل العمال دون استطلاع.
هل تنظف الإدخالات القديمة؟
فقط إذا فعّلت خيار مدة الحياة الاختياري، الذي يحذف الإدخالات التي لم يعد لها مشترك.
التفاصيل
الوصف الأصلي من المؤلف
Schema-validated, reactive registry for named configuration entries — the runtime configuration surface used by engine and Compose workers.
repo: iii-hq/iii
الشعبية
- نجوم GitHub
- 19k
- الترتيب
- #10486
- الترخيص
- —
- آخر تحديث
- 2/11/2026
التعليقات
- …
المزيد من المهارات من هذا المستودع
iii-sandbox
19kيساعد وكيلك على تشغيل كود غير موثوق أو مولّد بالذكاء الاصطناعي داخل جهاز افتراضي معزول ومؤقت، ثم يُتخلص منه بعد الانتهاء.
iii
19kيعلّم وكيلك كيف تعمل عمال iii، فيستطيع إضافة قدرة بالتحقق أولاً مما هو موجود، ثم بناء عامل جديد عند الحاجة.
iii-observability
19kيساعد وكيلك على إضافة التتبع والسجلات المنظمة والمقاييس والتنبيهات إلى محرك iii، باستخدام OpenTelemetry لترى ما يحدث في نظامك.
iii-stream
19kيشرح عامل iii-stream للبيانات الحية. وقد أُهمل ومن المقرر حذفه في إصدار قادم، لذا خطط للانتقال بعيداً عنه.
مهارات مشابهة
api-connector-builder
280kيبني وكيلك اتصالات API جديدة على النمط الموجود، ويفيد عندما تحتاج إلى تكامل إضافي دون ابتكار طريقة جديدة للعمل.
api-design
280kيساعد وكيلك على تصميم واجهات REST API وفق أفضل الممارسات، ويوضح كيف تتواصل وكيف تُعرض الأخطاء وكيف تُنظَّم البيانات.
backend-patterns
280kيساعد وكيلك على أنماط بنية الخادم وتحسين قاعدة البيانات، ويفيد في بناء الشيفرة التي تعمل على الخادم أو مراجعتها.