io.github.alexeibespalov/trident

السجل الرسمي الذكاء الاصطناعي والوكلاء

Create and edit collaborative architecture diagrams with any AI assistant using the Trident 2D DSL.

التثبيت

أضف هذا إلى إعدادات MCP في عميلك (Claude Desktop: claude_desktop_config.json، وCursor: ‏.cursor/mcp.json، ويستخدم VS Code وغيره الصيغة نفسها «mcpServers»).

Remote (streamable-http)
Claude Code
claude mcp add --transport http trident 'https://mcp.tridentchart.com/mcp'
إعداد JSON (Claude Desktop وCursor وVS Code)
{
    "mcpServers": {
        "trident": {
            "type": "http",
            "url": "https://mcp.tridentchart.com/mcp"
        }
    }
}
NPM package trident-mcp
Claude Code
claude mcp add trident -e 'TRIDENT_API_KEY=<TRIDENT_API_KEY>' -- npx -y trident-mcp@1.0.2
إعداد JSON (Claude Desktop وCursor وVS Code)
{
    "mcpServers": {
        "trident": {
            "command": "npx",
            "args": [
                "-y",
                "trident-mcp@1.0.2"
            ],
            "env": {
                "TRIDENT_API_KEY": "<TRIDENT_API_KEY>"
            }
        }
    }
}

متغيرات البيئة

  • TRIDENT_API_KEY Optional Trident API key for document editing tools. Spec tools work without a key.

التوثيق

مأخوذ من ملف README للمشروع على GitHub ويُحدَّث أسبوعيًا. تفتح الروابط على GitHub.

المحتويات
  1. Trident — Public
  2. What's here
  3. Quick start
  4. Markup format
  5. License

Trident — Public

Open-source core of Trident — a text-based diagramming tool.

This repo contains the parser, serializer, and read-only renderer. No auth, no collaboration, no dependencies.


What's here

FilePurpose
parser.jsParses Trident markup text → graphData object
trident-serializer.jsSerializes graphData → Trident markup text
renderer-oss.jsRead-only renderer: SVG, PNG, interactive canvas
spec.mdFull language specification
example.mdWorking diagram examples
demo.htmlBrowser demo (open directly, no build step)

Quick start

<script type="module">
import { Trident2DParserV2 } from './parser.js';
import { renderToSVG, renderToPNG, mountViewer } from './renderer-oss.js';

const parser = new Trident2DParserV2();

const markup = `trident
container backend color:#4A90E2 label:"Backend"
node api[API Server] in backend at (150, 100)
node db[Database]   in backend at (350, 100)
api --> |Query| db`;

// SVG string
const svg = await renderToSVG(markup, parser);

// Interactive canvas with zoom + pan (no editing)
await mountViewer(document.getElementById('diagram'), markup, parser);

// PNG blob (2× retina)
const blob = await renderToPNG(markup, parser, { scale: 2 });
</script>

Open demo.html directly in a browser to see it running.


Markup format

trident

container <id> [color:<hex>] [label:"<text>"] [at (<x>, <y>)]
node <id>(<icon>)[<label>] [in <container>] [at (<x>, <y>)] [color:<hex>]
<source> --> <target>
<source> -->|<label>| <target>
text <id> "<content>" at (<x>, <y>) [style:stickyNote|textBody]

See spec.md for the full grammar and example.md for complete working diagrams.


License

MIT

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

ما هو io.github.alexeibespalov/trident؟

Create and edit collaborative architecture diagrams with any AI assistant using the Trident 2D DSL.

كيف أثبّت io.github.alexeibespalov/trident؟

يعمل كخادم بعيد. في Claude Code: claude mcp add --transport http trident 'https://mcp.tridentchart.com/mcp'. وفي العملاء الآخرين، الصق إعداد JSON من هذه الصفحة في إعدادات MCP الخاصة بهم.

هل يحتاج io.github.alexeibespalov/trident إلى مفتاح API؟

لا يذكر إدراجه في السجل أي مفتاح أو سر إلزامي. قد تتطلب بعض الميزات حسابًا لدى الخدمة التي يتصل بها.

هل io.github.alexeibespalov/trident مفتوح المصدر؟

شيفرته علنية على GitHub، لكن المستودع لا يعلن ترخيصًا قياسيًا.

من يصون io.github.alexeibespalov/trident؟

ينشره alexeibespalov. يدرجه AI.tn لكنه لا يصونه ولا يوصي به.

من سجل MCP الرسمي. الإدراج ليس توصية: راجع شيفرة الخادم وصلاحياته قبل منحه الوصول إلى بياناتك.