شعار New Dcode Agent

New Dcode Agent

المجتمع
EliaAlberti
new-dcode-agent

Scaffold a new Deep Agents (LangChain) agent, a dcode CLI agent, or both, from one command. Use ONLY when the user explicitly runs /new-dcode-agent; never auto-trigger. It interviews the user (form, name, purpose, tools, model, safety), shows a spec, and on confirmation writes a self-contained agent into the user's current project (and/or a dcode CLI agent under ~/.deepagents). The agents it writes work with any OpenAI-compatible API via environment variables.

Add to TypingMind

نظرة عامة

الناشرEliaAlberti
المستودعdcode-agent-kit
اسم المهارةnew-dcode-agent
النجوم
56
التفريعات
12
الملفات المرفقة
تعليمات فقط
الترخيصMIT
الروابط
  • تعليمات بصيغة Markdown

    ملف SKILL.md يُحمّله النموذج عند الحاجة، فلا يستهلك توكنات إلا عندما يَرِد طلب ذو صلة فعلًا.

  • تعمل مع أي نموذج لغوي كبير

    مهارات الذكاء الاصطناعي مكتوبة بصيغة Markdown وليست شيفرة خاصة بمزوّد معيّن، لذا تعمل مع GPT أو Claude أو Gemini أو Grok أو نموذج محلي.

  • مكتفية بذاتها

    كل ما يحتاجه النموذج موجود في التعليمات — لا ملفات إضافية لمزامنتها.

  • مفتوحة المصدر

    نشرها EliaAlberti على GitHub. اطّلع على المصدر قبل تثبيتها.

التثبيت

ثبّت مهارة الذكاء الاصطناعي New Dcode Agent في TypingMind لاستخدامها مع أي نموذج لغوي كبير، أو أضفها إلى وكيل ذكاء اصطناعي آخر يقرأ SKILL.md.

1

التثبيت في TypingMind

يُثبّت TypingMind المهارة مباشرةً من مجلدها على GitHub — فيقرأ SKILL.md، ويجمع ملفات الموارد في حزمة، ويحفظ النتيجة محليًا.

  1. افتح التطبيق وانتقل إلى «الإضافات» ثم «المهارات».
  2. اختر «تثبيت من GitHub».
  3. الصق رابط مجلد المهارة الموضّح أدناه وأكّد التثبيت.
    https://github.com/EliaAlberti/dcode-agent-kit/tree/main/skills/new-dcode-agent
  4. فعّل المهارة في كل محادثة تريد إتاحتها فيها.
الإضافات ← المهارات ← إضافة مهارة ← من رابط GitHub، ثم الصق رابط المجلد واضغط على «متابعة».
2

التثبيت في وكيل ذكاء اصطناعي آخر

يمكن لأي وكيل ذكاء اصطناعي يقرأ تنسيق Agent Skills استخدام هذه المهارة — انسخ المجلد إلى مجلد المهارات الخاص بذلك الوكيل.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/EliaAlberti/dcode-agent-kit.git /tmp/dcode-agent-kit
mkdir -p .claude/skills
cp -r /tmp/dcode-agent-kit/skills/new-dcode-agent .claude/skills/new-dcode-agent
أعد تشغيل Claude Code بعد النسخ ليتعرّف على المهارة الجديدة.

استخدمها في TypingMind

فعّل New Dcode Agent في أي محادثة على TypingMind وسيتولى النموذج الباقي. تتضمن مطالبة النظام اسمها ووصفها، وبمجرد ورود طلب ذي صلة، يُحمّل النموذج التعليمات الكاملة تلقائيًا — فلا تحتاج إلى استدعائها يدويًا، ولا تستهلك أي توكنات حتى تُستخدم فعليًا.

يُحمّل النموذج مهارة New Dcode Agent تلقائيًا بمجرد ورود طلب ذي صلة بها.

تعمل مع أي نموذج ذكاء اصطناعي

مهارات الذكاء الاصطناعي هي تعليمات بصيغة Markdown وليست شيفرة خاصة بمزوّد معيّن، لذا لا ترتبط New Dcode Agent بالنموذج الذي كُتبت له. ثبّتها مرة واحدة في TypingMind واستخدمها مع GPT-5 أو Claude أو Gemini أو Grok أو DeepSeek أو Mistral أو Llama أو نموذج محلي تشغّله بنفسك — كل ذلك باستخدام مفاتيح API الخاصة بك.

  • تُحمَّل عند الحاجة فقط

    تتضمن مطالبة النظام الاسم والوصف فقط. وتُجلب التعليمات عند أول طلب ذي صلة، لذا لا تستهلك تعليمات المهارة أي توكنات ما دامت المهارة غير مستخدمة.

  • بدّل النماذج أثناء المحادثة

    لأن المهارة تعليمات وليست شيفرة، فإن تغيير النموذج لا يعطّلها — فالنموذج التالي يقرأ ملف SKILL.md نفسه.

تعليمات المهارة

هذا هو محتوى SKILL.md الذي يُحمّله النموذج. اقرأه قبل التثبيت — فالمهارة عبارة عن تعليمات سيتبعها نموذجك.

/new-dcode-agent

You are running the /new-dcode-agent skill. It scaffolds a working agent for the user. Everything it writes is SELF-CONTAINED, so it works from any folder, with no dependency on this skill's own location. Run no git; the user commits.

The three forms (keep them straight)

  • SDK program: a standalone Python agent (LangChain create_deep_agent) the user runs or deploys. Scaffolded into ./<name>/ in the user's current directory.
  • dcode agent: a named identity for the dcode CLI (an AGENTS.md) the user chats with via /agents. Scaffolded into ~/.deepagents/<name>/AGENTS.md.
  • both: a dcode agent that acts as the cockpit for a deployed SDK program.

(This is NOT Claude Code's own subagents, which are a different feature.)

Phase 1: Interview (use AskUserQuestion; batch related questions)

  1. Form: SDK program / dcode agent / both.
  2. name (kebab-case; reject names starting with _, names that match an existing target, or shell-unsafe names).
  3. purpose: one or two sentences.
  4. (SDK or both): closest starting flavour (custom / project / work-jira / vps-ops / personal); the tools it needs (plain Python functions, plus any MCP servers); the model (a provider:model string for any LangChain provider, or the bundled env-driven connector below); does it change anything? (if yes, it gets an approval gate); how it will run (one-shot / long-running / scheduled / server).
  5. (dcode agent or both): what it knows and operates; which tools or MCP it leans on; its operating rules.

Phase 2: Spec

Show the user exactly what you will create: the target paths, the tools, the model, and the safety posture. Wait for explicit confirmation. Do not write anything until they confirm.

Phase 3: Scaffold

SDK program (form = SDK or both): write ./<name>/ in the user's current directory

Create the folder <name>/ with three files. It is self-contained: agent.py imports its connector from the sibling model.py (a same-directory import, so there is no path manipulation at all).

<name>/model.py (write this verbatim; the env-driven, provider-agnostic connector):

python
"""Model connector for this agent. Provider-agnostic, configured from the environment.

Targets any OpenAI-compatible Chat Completions endpoint (OpenAI itself, or a compatible
gateway). Set these in the environment or a .env file next to this agent:
  LLM_API_KEY     (or OPENAI_API_KEY)   required
  LLM_BASE_URL    (or OPENAI_BASE_URL)  optional; omit for OpenAI's default endpoint
  LLM_MODEL                             optional; the model id (default below)
  USE_RESPONSES_API                     optional; set 1 only if your provider supports it
"""
from __future__ import annotations

import os
import pathlib

from langchain_openai import ChatOpenAI

DEFAULT_MODEL = "gpt-4o-mini"  # override via LLM_MODEL or the model= argument


def _load_env() -> None:
    """Minimal .env loader (no extra deps): this agent's folder, then the current
    directory, then ~/.deepagents/.env. Existing environment variables always win."""
    here = pathlib.Path(__file__).resolve().parent
    for path in (here / ".env", pathlib.Path.cwd() / ".env",
                 pathlib.Path.home() / ".deepagents" / ".env"):
        if not path.is_file():
            continue
        for line in path.read_text().splitlines():
            line = line.strip()
            if not line or line.startswith("#") or "=" not in line:
                continue
            key, value = line.split("=", 1)
            os.environ.setdefault(key.strip(), value.strip())


def chat_model(model: str | None = None, *, temperature: float = 0.0, **kwargs) -> ChatOpenAI:
    """Return a ChatOpenAI wired to your OpenAI-compatible provider, from env."""
    _load_env()
    key = os.environ.get("LLM_API_KEY") or os.environ.get("OPENAI_API_KEY")
    if not key:
        raise RuntimeError("No API key. Set LLM_API_KEY (or OPENAI_API_KEY) in the "
                           "environment or a .env file next to this agent.")
    base_url = os.environ.get("LLM_BASE_URL") or os.environ.get("OPENAI_BASE_URL") or None
    use_responses = os.environ.get("USE_RESPONSES_API", "").strip().lower() in ("1", "true", "yes")
    return ChatOpenAI(base_url=base_url, api_key=key,
                      model=model or os.environ.get("LLM_MODEL") or DEFAULT_MODEL,
                      temperature=temperature, use_responses_api=use_responses, **kwargs)

<name>/agent.py (base, non-mutating flavour; fill in system_prompt and real tools):

python
"""<name>: a Deep Agents SDK agent. Run:  python agent.py "your prompt" """
from __future__ import annotations

import sys

from model import chat_model  # sibling model.py, same-directory import
from deepagents import create_deep_agent


def example_tool(query: str) -> str:
    """Describe what this tool does (stub; replace)."""
    return f"[stub] {query}"


SYSTEM_PROMPT = """You are a helpful agent. TODO: describe the role, scope, and rules."""


def build_agent():
    return create_deep_agent(
        model=chat_model(),          # your provider/model from env; pass an id to override
        tools=[example_tool],
        system_prompt=SYSTEM_PROMPT,
    )


if __name__ == "__main__":
    agent = build_agent()
    prompt = " ".join(sys.argv[1:]) or "Hello"
    res = agent.invoke({"messages": [{"role": "user", "content": prompt}]})
    print(res["messages"][-1].content)

If the agent can change things (a mutating tool), use this gated pattern instead. The approval gate needs BOTH interrupt_on AND a checkpointer, or it silently does nothing:

python
"""<name>: an ops agent with an approval gate. Run:  python agent.py "status check" """
from __future__ import annotations

import sys

from model import chat_model
from deepagents import create_deep_agent
from langgraph.checkpoint.memory import InMemorySaver


def check_status() -> str:
    """Read-only status check (stub)."""
    return "ok"


def restart_service(service: str) -> str:
    """MUTATING, gated by approval."""
    return f"[would restart {service}]"


def build_agent():
    return create_deep_agent(
        model=chat_model(),
        tools=[check_status, restart_service],
        system_prompt="You are an ops engineer. Investigate read-only first; changes need approval.",
        interrupt_on={"restart_service": True},
        checkpointer=InMemorySaver(),   # required, or the gate no-ops
    )


if __name__ == "__main__":
    agent = build_agent()
    cfg = {"configurable": {"thread_id": "s1"}}
    res = agent.invoke({"messages": [{"role": "user", "content": " ".join(sys.argv[1:]) or "status check"}]}, config=cfg)
    print("[paused for approval]" if res.get("__interrupt__") else res["messages"][-1].content)

Verify a mutating agent actually pauses (a single __interrupt__ check can false-negative):

python
cfg = {"configurable": {"thread_id": "verify"}}
res = agent.invoke({"messages": [{"role": "user", "content": "<ask it to run the mutating tool>"}]}, config=cfg)
paused = bool(res.get("__interrupt__")) or bool(getattr(agent.get_state(cfg), "next", None))
print("approval gate fired:", paused)   # if False, fix interrupt_on + checkpointer before shipping

Flavour adjustments (start from the base or gated file above and change these):

  • custom: the base file as-is. A blank starting point.
  • project: a code/repo assistant. Add a read-only run_tests() tool (shell out to the project's test command) and a senior-engineer system prompt. Point LLM_MODEL at a coding-tuned model.
  • work-jira: a Jira assistant. Either stub search_issues(jql), or load MCP tools with langchain-mcp-adapters (MultiServerMCPClient) reading JIRA_* from the environment at runtime. Never hard-code credentials.
  • vps-ops: a server-ops agent. Use the GATED pattern above (mutating tools behind interrupt_on + InMemorySaver).
  • personal: a personal-assistant agent. Add simple tools (read a tasks file, append a note) and a concise system prompt.

<name>/README.md (write a short one): what the agent does, then:

bash
pip install deepagents langchain-openai   # plus langchain-mcp-adapters if it uses MCP
export LLM_API_KEY=your-key                # or put it in a .env next to agent.py
# optional: export LLM_BASE_URL=...  export LLM_MODEL=...
python agent.py "your prompt"

dcode agent (form = dcode agent or both): write ~/.deepagents/<name>/AGENTS.md

  • Plain Markdown, NO YAML frontmatter: a dcode agent's AGENTS.md is memory layered on dcode's base prompt, loaded fresh each run (not a program).
  • Sections: Role (who it is, default posture); Context / setup (what it knows; commands it has; link extra files); How to operate (workflow; when to delegate to subagents); Operating rules (read-only default; approval before destructive actions; no secrets).
  • Keep it lean (injected every run); push bulky reference into separate files and reference them.
  • If the file already exists, preserve any <!-- ... --> managed block (dcode self-edits this file).
  • Optional subagents at ~/.deepagents/<name>/agents/<sub>/AGENTS.md. A subagent's frontmatter is only name, description, model (with a provider prefix, e.g. openai:gpt-4o-mini); the body is its system prompt; the folder and filename must be agents/<sub>/AGENTS.md.
  • If form = both: the dcode agent's AGENTS.md references the SDK program (its path and how to run it), so it is the interactive cockpit for the deployed agent.

Phase 4: Smoke-test

  • SDK: cd <name> && python agent.py "hello" (import plus a minimal run; construct-only if there is no key). If it mutates, run the verification snippet and confirm the gate fires.
  • dcode agent: confirm dcode agents list shows <name> (it auto-discovers the directory).

Guardrails (never violate)

  • No secrets in any file: keys come from the environment or a .env at runtime only.
  • The scaffolded SDK agent is self-contained: agent.py plus a sibling model.py, same-directory import, no path manipulation.
  • A mutating tool MUST have interrupt_on plus a checkpointer, or the approval gate silently does nothing.
  • Provider-agnostic: never bake a provider, model id, or key into the generated code.
  • Run no git; the user commits.

الأسئلة الشائعة

ماذا تفعل مهارة الذكاء الاصطناعي New Dcode Agent؟

Scaffold a new Deep Agents (LangChain) agent, a dcode CLI agent, or both, from one command. Use ONLY when the user explicitly runs /new-dcode-agent; never auto-trigger. It interviews the user (form, name, purpose, tools, model, safety), shows a spec, and on confirmation writes a self-contained agent into the user's current project (and/or a dcode CLI agent under ~/.deepagents). The agents it writes work with any OpenAI-compatible API via environment variables.

لماذا تستخدم New Dcode Agent على TypingMind؟

لأنك تثبّتها مرة واحدة وتستخدمها مع أي نموذج. مهارة New Dcode Agent عبارة عن نص Markdown وليست شيفرة خاصة بمزود بعينه، لذا تعمل المهارة نفسها مع GPT-5 أو Claude أو Gemini أو Grok أو نموذج محلي، ويمكنك تبديل النموذج أثناء المحادثة دون تعطّل المهارة. يعمل TypingMind بمفاتيح API الخاصة بك، فتدفع للمزودين مباشرةً بدلًا من اشتراك لكل مقعد، وتبقى مهاراتك ومحادثاتك في مساحة التخزين الخاصة بك.

كيف أثبّت New Dcode Agent في TypingMind؟

في TypingMind، افتح «الإضافات»، ثم «المهارات»، ثم اختر «التثبيت من GitHub» والصق https://github.com/EliaAlberti/dcode-agent-kit/tree/main/skills/new-dcode-agent. يقرأ TypingMind ملف SKILL.md الخاص بالمهارة ويثبّتها كمهارة يمكنك تفعيلها لكل محادثة على حدة.

ما نماذج الذكاء الاصطناعي التي يمكنها استخدام New Dcode Agent؟

أي نموذج تربطه في TypingMind. مهارات الذكاء الاصطناعي عبارة عن تعليمات Markdown وليست شيفرة خاصة بمزود بعينه، لذا يمكن لكل من GPT وClaude وGemini وGrok والنماذج المحلية تحميل هذه المهارة عندما يتوافق الطلب معها.

كم نموذج ذكاء اصطناعي يمكنني استخدامه مع New Dcode Agent؟

أي عدد تريده. ما دام النموذج يدعم المهارات، يمكنك استخدام New Dcode Agent معه، سواء كان GPT أو Claude أو Gemini أو Grok أو DeepSeek أو Mistral أو Llama أو غيرها، وكل ذلك على TypingMind باستخدام مفاتيح API الخاصة بك.

هل مهارة الذكاء الاصطناعي New Dcode Agent مجانية؟

نعم. نشرها EliaAlberti على GitHub بموجب ترخيص MIT. لا تدفع إلا لمزود الذكاء الاصطناعي الخاص بك مقابل التوكنات التي تستخدمها.

ما هي مهارات الذكاء الاصطناعي؟

مهارة الذكاء الاصطناعي حزمة تعليمات قابلة لإعادة الاستخدام تعلّم نموذج الذكاء الاصطناعي كيفية تنفيذ مهمة محددة. وتتبع تنسيق Agent Skills المفتوح: ملف SKILL.md يتضمن اسمًا ووصفًا، إلى جانب أي نصوص برمجية أو قوالب أو ملفات مرجعية قد يحتاج إليها النموذج. لا يقرأ النموذج التعليمات إلا عندما يتوافق طلبك مع المهارة، لذا لا تترتب على المهارة المثبتة أي تكلفة حتى تُستخدم.

كيف تختلف مهارات الذكاء الاصطناعي عن الإضافات أو موصلات MCP؟

تمنح الإضافة أو موصل MCP النموذج أدوات جديدة يمكنه استدعاؤها، وهي شيفرة تُنفَّذ في مكان ما وتُرجع نتيجة. أما مهارة الذكاء الاصطناعي فتزوّد النموذج بالمعرفة ومنهجية العمل: كيفية التعامل مع مهمة، والخطوات التي ينبغي اتباعها، وما ينبغي أن تكون عليه المخرجات الجيدة. المهارات عبارة عن نصوص Markdown، لذا لا تحتاج إلى خادم أو مفتاح API أو بيئة تشغيل، وتعمل مع أي نموذج.

عرض الكل
شعار openclaw

Graincrawl

openclaw
مؤسسةشائع

أرشيف Granola: البحث، وحداثة المزامنة، والملاحظات، والنصوص المفرغة، واللوحات، وإحصاءات SQL، وأعمال مستودعات Graincrawl.

82.2K
391K
الملفات: 1
عرض
شعار openclaw

Openclaw Changelog Update

openclaw
مؤسسةشائع

أعِد إنشاء أقسام سجل تغييرات إصدارات OpenClaw استنادًا إلى سجل git قبل إصدارات beta أو stable أو extended-stable.

82.2K
391K
الملفات: 1
عرض
شعار openclaw

Openclaw Ci Limits

openclaw
مؤسسةشائع

أدِر سعة GitHub Actions وBlacksmith CI في OpenClaw، وميزانيات تسجيل المشغّلات، وحدود التوزيع المتوازي، وضمان تشغيل مهمة واحدة لكل دفعة دفع إلى main، وتحديد أحجام الأجزاء، ونقل الأحمال إلى المشغّلات المستضافة، وصحة قائمة الانتظار، والتدرّج الآمن في خفض السعة وزيادتها…

82.2K
391K
الملفات: 1
عرض
شعار openclaw

Openclaw Debugging

openclaw
مؤسسةشائع

شخّص مشكلات النماذج ومزوّدي الخدمة وواجهات الأدوات ووضع البرمجة والبث المباشر وسلوك OpenClaw المباشر/Crabbox، باختيار السجلات والفحوصات ومسار التحقق المناسب قبل تغيير الشيفرة، بما في ذلك جلب الجلسات المحفوظة…

82.2K
391K
الملفات: 1
عرض

أنشئ مساحة عملك للذكاء الاصطناعي الآن

اشترك في نشرتنا الإخبارية لتصلك أخبار الميزات الجديدة والهدايا القادمة 👇