operator-approval-loop
ما الذي تفعله
يضمن هذا النظام أن الرسائل المهمة التي يكتبها وكيل الذكاء الاصطناعي للآخرين تراجعها وتوافق عليها شخصية قبل إرسالها. ويحتفظ بسجل لكل ما أُرسل ومن وافق عليه.
متى تستخدمها
- ✓عندما يكتب وكيل الذكاء الاصطناعي ردودًا للعملاء أو الشركاء.
- ✓عندما تحتاج إلى سجل دقيق لمعرفة من وافق على كل رسالة.
- ✓عندما تريد منع إرسال رسائل خاطئة أو مكررة.
رابط المهارة
https://github.com/affaan-m/ECC/blob/main/skills/operator-approval-loop/SKILL.mdانسخه والصقه في الذكاء الاصطناعي الذي تستخدمه (Claude أو ChatGPT أو Cursor) واطلب منه اتباع التعليمات.
طريقة الاستخدام
أسهل طريقة: انسخ الرسالة والصقها في الذكاء الاصطناعي الذي تستخدمه. سيقرأ المهارة وينفّذ تعليماتها.
رسالة جاهزة للصق
لـ Claude Code أو Codex أو Cursor: شغّله داخل مجلد مشروعك وستُثبَّت المهارة.
نزّل ملف SKILL.md وضعه في مجلد مهارات وكيلك.
مثال على ما تطلبه من الذكاء الاصطناعي
“راجع هذه الرسالة للعميل بشأن حالة طلبه ووافق عليها، من فضلك.”
5 مهارات جديدة كل أسبوع. قراءة في دقيقة واحدة.
كيف تعمل
عند إنشاء الرسالة تُحفظ كمسودة وتُعلَّم للمراجعة. يراجع الإنسان المسودة فيوافق عليها أو يرفضها. وإذا وافق، يسجّل النظام من وافق ومتى، ويضمن إرسال الرسالة المعتمدة بالضبط.
المحتوى التقني (ملف SKILL.md الأصلي)
النص الأصلي من المؤلف، مباشرة من GitHub.
Operator Approval Loop
An agent that talks to external counterparties should never send on its own judgment and should keep the operator informed internally. This skill defines the contract: every outbound draft is filed as an obligation, an operator decides on the exact text, and a delivery ledger proves what went out.
When to Use
- An agent drafts replies to customers, suppliers, investors, or partners in a shared channel, email, or chat, and a human must approve before send.
- You need an audit trail that links each sent message to the exact draft text, the operator who approved it, and the decision time.
- You have seen a stale approval release a rewritten draft, or two workers deliver the same approved message twice.
- Drafts keep re-asking counterparties for facts the ledger already holds.
How It Works
Objects
| Object | Meaning |
|---|---|
| Obligation | One thing we owe a counterparty. Status moves drafted, then approved or rejected, then sent. Carries direction, counterparty, channel, and an updated_at epoch. |
| Draft | Sidecar row holding the exact draft text, a sha256 of that text, origin coordinates (platform, channel, thread, user), and priority (P0 to P3). One per obligation, replaced on re-file. |
| Decision | An operator's approve or reject, recorded with the operator id, a nonce, and the draft epoch it was made against. |
| Approval snapshot | Immutable text, hash, epoch and destination recorded by the already-authorized decision writer. Missing snapshots cannot grant dispatch. |
| Claim | Durable reservation with a random token and state; at most one active claim per obligation. |
| Delivery | Ledger row proving one send or notice for one (obligation, decision) pair. |
The reference schema is in references/approval-ledger.sql.
Filing a draft
- Clean inputs. Strip control characters, collapse whitespace in single-line fields, and enforce length caps (draft, summary, context, counterparty). Empty or oversized fields are refused, not truncated silently.
- Run the baseline gate (below). It may refuse the filing.
- Hash the draft text with sha256. The hash prefix goes into the summary so the approval panel shows which text it is approving.
- Upsert. If an open drafted obligation already exists for the same
(counterparty, channel), replace the draft sidecar and advance the
obligation's
updated_at. That advance is the epoch rotation: any decision keyed to the old epoch can no longer release the new text. Otherwise insert a new obligation with statusdrafted. - Route the filing receipt only to a configured, verified internal ops destination. If the origin is that internal destination, acknowledge there. Never-silent means internal reporting, not an automatic external reply. Keep draft hashes, approval status, operator identity and workflow metadata out of counterparty-visible channels. Unknown or unclassified origins stay quiet; a direct message is not automatically internal.
If a verified internal destination is unavailable, retain the filing result in the internal tool result or operator surface. Never fall back to an external or unknown origin. A tool result exposed to outsiders is not an internal surface.
Filing a draft does not authorize an external response. Any policy-permitted clarifying question or neutral response is a separate outbound decision, subject to the existing mention, channel, draft-only, frozen and never constraints in counterparty-channel-discipline. It must not disclose internal approval metadata.
Baseline gate
Before any draft is filed, query the current baseline for the counterparty (a temporal ledger, contract store, or CRM):
- Signed or delivered contract on record: refuse the filing with the evidence and a recommendation. Asking a counterparty about specs after signing is the exact failure this gate exists to stop.
- Operator override:
force_despite_signed_contractlets the filing through and stamps[BASELINE_OVERRIDE_SIGNED_CONTRACT]into the draft context. - Gate service unreachable: the filing proceeds and the context is stamped
[BASELINE_CHECK_UNAVAILABLE]. The panel sees that the guard was off. Failures never silently disable the gate. - When facts are available, attach the freshest few to the context as a
[BASELINE FACTS: ...]digest so the draft lands with current truth.
Deciding
…
الأسئلة الشائعة
ماذا يحدث إذا تغيرت المسودة بعد الموافقة عليها؟
إذا تغيرت المسودة بعد الموافقة، تحتاج إلى مراجعة جديدة وموافقة جديدة. هكذا تتأكد أن الرسالة المرسلة هي التي وافق عليها الشخص فعلًا.
كيف يمنع النظام إرسال الرسالة نفسها مرتين؟
يحتفظ النظام بسجل لكل الرسائل المرسلة والمعتمدة. وقبل الإرسال يتحقق مما إذا كانت رسالة مطابقة قد أُرسلت بناءً على الموافقة المقابلة.
ما هي «بوابة خط الأساس»؟
هي فحص أولي يراجع المعلومات الموجودة عن المستلم، مثل العقود الموقعة، قبل السماح بإنشاء مسودة. وهذا يمنع الوكيل من طلب معلومات يُفترض أنها معروفة مسبقًا.
التفاصيل
الوصف الأصلي من المؤلف
Operator approval contract with internal filing notices for agent-drafted outbound messages, hashed drafts, epoch-keyed decisions, durable delivery claims and receipts, and a pre-draft baseline gate. Use when an agent drafts messages to external counterparties and a human operator must approve, reject, or steer each send before it leaves.
repo: affaan-m/ECC
الشعبية
- نجوم GitHub
- 280k
- الترتيب
- #371
- الترخيص
- MIT
- آخر تحديث
- 15/10/2026
التعليقات
- …
المزيد من المهارات من هذا المستودع
accessibility
280kيساعد وكيلك على بناء واجهات يستطيع الجميع استعمالها، ويضمن عمل المواقع والتطبيقات جيدًا لذوي الإعاقة، كالمكفوفين وذوي الحركة المحدودة.
agent-architecture-audit
280kيتأكد وكيلك من أن كل شيء يعمل بشكل صحيح، ويجد مشكلات أنظمة الذكاء الاصطناعي ويصلحها، ليؤدي كما هو متوقع.
agent-eval
280kيساعد وكيلك على مقارنة أدوات البرمجة بالذكاء الاصطناعي المختلفة، ويقيس أيها أسرع وأرخص وأكثر موثوقية لمهام محددة.
agent-harness-construction
280kيساعد وكيلك على فهم طريقة إنجاز المهام بشكل أفضل، عبر تحسين الأدوات والتعليمات التي يستعملها لزيادة فرص نجاحه.
مهارات مشابهة
discord-user-post
394kتتيح لوكيلك نشر رسالة وافقت عليها في Discord باسمك عبر تطبيق Discord على سطح المكتب، بعد التأكد من القناة المحددة.
configure-channel
394kتعلّم وكيلك كيف يربط تطبيق محادثة مثل Telegram بـ OpenClaw، ويخزّن رمز البوت بأمان، ويتحقق من أن الرسائل تصل.
discord
394kيساعد وكيلك على قراءة رسائل Discord وإرسالها وتعديلها والتفاعل معها عبر OpenClaw، مع التحقق من الرسالة بدقة قبل أي تغيير.