Logo Knowledge Setup

Knowledge Setup

Tổ chức
Cognigy
knowledge-setup

Use when the user wants to add knowledge, RAG, or a knowledge store/source to a Cognigy agent — covers embedding vs Knowledge Search models, Knowledge AI settings, ingesting sources, and attaching knowledge as a tool.

Tổng quan

Nhà phát hànhCognigy
Kho mãcognigy-plugin
Tên kỹ năngknowledge-setup
Sao
20
Bản fork
14
Tệp đi kèm
Chỉ có hướng dẫn
Giấy phépMIT
Liên kết
  • Hướng dẫn bằng Markdown

    Tệp SKILL.md được mô hình tải khi cần, nên chỉ tốn token khi có yêu cầu thực sự phù hợp.

  • Dùng được với mọi LLM

    Kỹ năng AI là Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên dùng được với GPT, Claude, Gemini, Grok hoặc mô hình cục bộ.

  • Đầy đủ trong hướng dẫn

    Mọi thứ mô hình cần đều nằm trong hướng dẫn — không có tệp bổ sung cần đồng bộ.

  • Mã nguồn mở

    Được Cognigy công bố trên GitHub. Hãy đọc nội dung nguồn trước khi cài đặt.

Cài đặt

Cài đặt kỹ năng AI Knowledge Setup trong TypingMind để dùng với bất kỳ LLM nào, hoặc thêm vào một tác nhân AI khác có thể đọc SKILL.md.

1

Cài đặt trong TypingMind

TypingMind cài đặt kỹ năng trực tiếp từ thư mục GitHub — đọc SKILL.md, đóng gói các tệp tài nguyên và lưu kết quả trên máy.

  1. Mở ứng dụng và vào Plugin → Kỹ năng.
  2. Chọn "Cài đặt từ GitHub".
  3. Dán URL thư mục kỹ năng bên dưới và xác nhận.
    https://github.com/Cognigy/cognigy-plugin/tree/main/plugin/skills/knowledge-setup
  4. Bật kỹ năng trong từng cuộc trò chuyện mà bạn muốn sử dụng kỹ năng đó.
Plugin → Kỹ năng → Thêm kỹ năng → Từ URL GitHub, sau đó dán URL thư mục và nhấn Tiếp tục.
2

Cài đặt trong tác nhân AI khác

Bất kỳ tác nhân AI nào đọc được định dạng Agent Skills đều có thể dùng kỹ năng này — hãy sao chép thư mục vào thư mục kỹ năng của tác nhân AI đó.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Cognigy/cognigy-plugin.git /tmp/cognigy-plugin
mkdir -p .claude/skills
cp -r /tmp/cognigy-plugin/plugin/skills/knowledge-setup .claude/skills/knowledge-setup
Khởi động lại Claude Code sau khi sao chép để ứng dụng nhận kỹ năng mới.

Sử dụng trong TypingMind

Bật Knowledge Setup trong bất kỳ cuộc trò chuyện nào trên TypingMind, mô hình sẽ tự xử lý phần còn lại. Tên và mô tả của kỹ năng nằm trong prompt hệ thống. Ngay khi có yêu cầu phù hợp, mô hình tự tải toàn bộ hướng dẫn — bạn không cần gọi thủ công và kỹ năng không tốn token cho đến khi thực sự được dùng.

Mô hình tự tải Knowledge Setup ngay khi có yêu cầu phù hợp.

Dùng được với mọi mô hình AI

Kỹ năng AI là các hướng dẫn Markdown thuần túy, không phải mã dành riêng cho một nhà cung cấp, nên Knowledge Setup không bị giới hạn ở mô hình mà kỹ năng này được viết cho. Chỉ cần cài đặt một lần trong TypingMind rồi dùng với GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama hoặc mô hình cục bộ do bạn tự chạy — tất cả đều dùng khóa API của riêng bạn.

  • Chỉ tải khi cần

    Prompt hệ thống chỉ chứa tên và mô tả. Hướng dẫn được tải khi có yêu cầu phù hợp đầu tiên, nên kỹ năng chưa dùng không tốn chi phí.

  • Đổi mô hình ngay trong cuộc trò chuyện

    Vì kỹ năng là hướng dẫn chứ không phải mã, việc đổi mô hình không làm kỹ năng ngừng hoạt động — mô hình tiếp theo vẫn đọc cùng tệp SKILL.md.

Hướng dẫn của kỹ năng

Đây là nội dung SKILL.md mà mô hình tải. Hãy đọc trước khi cài đặt — kỹ năng là những hướng dẫn mà mô hình của bạn sẽ làm theo.

Adding Knowledge to an Agent

Creating stores and sources is the same for both kinds of agent. To give an AI Agent (built with manage_agent) the store, set its knowledge block with manage_agent { operation: "update" } — see the agent-creation skill. The create_tool { toolType: "knowledge" } steps below are for legacy AI Agents.

Prerequisites

  • An embedding model must be configured in the project before creating knowledge stores. Use setup_llm to create one first if the target project does not already have one (e.g., setup_llm { projectId, provider: "openAI", modelType: "<embedding model type>", apiKey }). To check: list_resources { resourceType: "llm_model", projectId } and inspect modelType. Use provider docs or an existing same-project model to identify the correct embedding-capable model type for the store index.
  • Configure the project's Knowledge AI Settings before creating the store in normal AI-agent knowledge flows. Use manage_settings { operation: "set_knowledge_ai", projectId, knowledgeSearchModelId: "<llm referenceId>" }. If you use the Azure content parser, also set contentParser: "azure" and azureDIConnectionId.

Important Distinction

  • The embedding model is for the knowledge store index itself.
  • knowledgeSearchModelId is a separate project setting for Knowledge Search and must reference an llm_model from the same project.
  • For normal AI-agent knowledge-store setups, answerExtractionModelId is usually not needed.
  • The model you pick for the AI Agent itself is a separate decision. The agent response model should not be reused for knowledgeSearchModelId just because it is already available.
  • The accepted model type for knowledgeSearchModelId is instance-dependent. Start with existing same-project candidates and rely on the API response.
  • Model names shown in examples are not a whitelist for either role.

Steps

  1. list_resources { resourceType: "llm_model", projectId }
    • For Knowledge Search, prefer list_resources { resourceType: "llm_model", projectId, useCase: "knowledgeSearch" } so the candidates match the Settings UI dropdown
    • Refresh this after any package import
    • Start with the source project's exact Knowledge Search model when reusing an existing setup
    • Import the full required source-project model set before the first manage_settings { operation: "set_knowledge_ai", ... } attempt
    • If multiple required models share one connection, import that connection once alongside all of those models
  2. manage_settings { operation: "set_knowledge_ai", projectId, knowledgeSearchModelId, contentParser }
    • Do this before manage_knowledge { operation: "create_store", ... } in normal AI-agent knowledge flows
  3. manage_knowledge { operation: "create_store", projectId, name }
  4. manage_knowledge { operation: "create_source", knowledgeStoreId, type, ... }
    • type: "url" — scrape a web page. Provide url.
    • type: "manual" — store text directly. Provide text.
    • type: "file" — upload a local document. Provide filePath (absolute path, e.g. "/Users/me/docs/report.pdf").
    • IMPORTANT: URL and file ingestion is async. Content is NOT searchable immediately.
    • Wait 10-60 seconds before searching.
  5. manage_knowledge { operation: "list_chunks", knowledgeStoreId }
    • Verify content was ingested correctly (optional sourceId — defaults to the first source — and filter to match chunk text; list_sources shows all sources in the store)
    • If no results right after create_source, wait and retry
  6. Attach to agent as a TOOL (default approach):
    • During agent creation — create_ai_agent { projectId, name, knowledgeStoreReferenceId: storeReferenceId } This automatically creates a knowledge search tool on the agent's Job Node.
    • After agent creation — create_tool { aiAgentId, toolType: "knowledge", name: "Search KB", config: { knowledgeStoreId: storeReferenceId, toolId: "search_kb", description: "Search the knowledge base" } } This creates a dedicated search tool the agent can invoke to query the knowledge store.
    • IMPORTANT: Always use the tool-based approach unless the user explicitly asks to attach knowledge to the agent persona.

File Upload Notes

  • Supported formats: PDF, TXT, DOCX, CTXT, PPTX
  • Maximum file size: 10MB
  • Provide filePath with an absolute path — the server reads the file directly from disk
  • Tilde paths (~/Documents/file.pdf) are expanded automatically
  • The file extension determines how the content is processed

Tips

  • Search chunks to verify content before attaching to agent
  • For URLs, ensure the page is publicly accessible
  • Text sources are best for structured FAQ content
  • File sources are best for existing documents (PDFs, Word docs, etc.)

Model selection, reuse, caching, and reporting rules live in Workflow Policy below — the single source of truth. Tool-vs-persona attachment is covered in step 6 of Steps.

Workflow Policy (source of truth for model selection & reporting)

This section is the authoritative policy for knowledge workflows. Follow it over any hardcoded assumption.

  • There are TWO model roles you usually need for AI-agent knowledge workflows. Do not mix them up:
    1. Embedding model: required to create and use the knowledge store index itself.
    2. Knowledge Search model: project-level Knowledge AI setting used for knowledge search behavior.
  • Do not use hardcoded model-name assumptions as the source of truth for either role. Model names in guides are examples, not a whitelist.
  • For knowledgeSearchModelId, do NOT assume a chat model is always required, and do NOT assume an embedding model is always rejected. The accepted model type is instance-dependent. Treat the Cognigy API response as the source of truth.
  • Before calling setup_llm for knowledge workflows, ALWAYS list llm_model resources in the TARGET project and try/reuse imported same-project model IDs first.
  • When choosing knowledgeSearchModelId, prefer list_resources { resourceType: "llm_model", projectId, useCase: "knowledgeSearch" } so the candidate set matches the Cognigy Settings UI dropdown instead of the unfiltered project-wide LLM list.
  • After package import, refresh list_resources { resourceType: "llm_model", projectId } before deciding what to use for knowledgeSearchModelId. Otherwise do not re-scan the same unchanged project — reuse the previous llm_model results unless an import or setup_llm changed the state.
  • If another project already has a working knowledge workflow, inspect that source project's exact Knowledge Search model and Content Parser choice BEFORE the first set_knowledge_ai call in the target project.
  • Do NOT attempt knowledgeSearchModelId with the agent chat model or any other generic default until the source project's exact Knowledge Search choice has been imported and tried, or you have confirmed that no such source-project choice is available.
  • If manage_settings rejects one knowledgeSearchModelId with a message like "model type not allowed", try other existing llm_model IDs in the SAME project before creating a new model.
  • For normal AI-agent knowledge flows, set Knowledge AI Settings with manage_settings BEFORE creating the knowledge store or uploading sources.
  • Do NOT substitute a freshly created or generic model for knowledgeSearchModelId just because the user asked for a new project. Reuse the imported same-project model that matches the source project's Knowledge Search choice when available.
  • If an imported same-project model is rejected for knowledgeSearchModelId, do NOT call setup_llm to create another model as a workaround unless the user explicitly asks for a brand-new model after you have exhausted the existing target-project candidates.
  • Keep the AI Agent response model choice separate from the Knowledge Search model choice. The model preferred for agent responses is not a reason to try that same model for knowledgeSearchModelId.
  • Do NOT speculatively probe arbitrary unfiltered models for knowledgeSearchModelId before trying the source project's known Knowledge Search model or the other existing same-project candidates.
  • For knowledge workflows, import the full required source-project model set up front before the first Knowledge AI settings attempt: the embedding model, the exact source-project Knowledge Search model, and any other required LLMs for the workflow. If the agent also needs a separate response model, transfer that as part of the same plan.
  • When multiple required LLMs share the same source-project connection, export/import all of those llm_model resources together with that single connection resource in one package. Do NOT re-import the same shared connection in a later package just to bring over another model.
  • If the exact source-project Knowledge Search model is not yet present in the target project, stop and import it before retrying set_knowledge_ai. Do NOT fall back to an arbitrary generic model first.
  • If the useCase-filtered knowledgeSearch list contains only one real candidate, do NOT speculate outside that list before trying it and reporting the result.
  • When reporting blockers or partial completion, distinguish observed tool errors from inference. Do not claim a setting or model is broken unless a tool call actually returned that failure.
  • Do not describe a knowledgeSearchModelId rejection as a platform-side bug just because a similar model worked in another project. Report the exact target-project attempts and failures only.
  • Do not say an untried model is "likely" rejected or unsupported. Only report actual API validation results for models you tried.

Câu hỏi thường gặp

Kỹ năng AI Knowledge Setup làm được gì?

Use when the user wants to add knowledge, RAG, or a knowledge store/source to a Cognigy agent — covers embedding vs Knowledge Search models, Knowledge AI settings, ingesting sources, and attaching knowledge as a tool.

Vì sao nên dùng Knowledge Setup trên TypingMind?

Vì bạn chỉ cần cài một lần rồi dùng với bất kỳ mô hình nào. Knowledge Setup là nội dung Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên cùng một kỹ năng có thể chạy trên GPT-5, Claude, Gemini, Grok hoặc mô hình trên thiết bị — và bạn có thể đổi mô hình ngay trong cuộc trò chuyện mà kỹ năng vẫn hoạt động. TypingMind dùng khóa API riêng của bạn, nên bạn thanh toán trực tiếp cho nhà cung cấp thay vì trả phí thuê bao theo suất người dùng, đồng thời kỹ năng và các cuộc trò chuyện vẫn nằm trong bộ lưu trữ của bạn.

Làm thế nào để cài Knowledge Setup trong TypingMind?

Mở Plugin → Kỹ năng → Cài đặt từ GitHub trong TypingMind rồi dán https://github.com/Cognigy/cognigy-plugin/tree/main/plugin/skills/knowledge-setup. TypingMind đọc tệp SKILL.md và cài đặt thành một kỹ năng mà bạn có thể bật cho từng cuộc trò chuyện.

Những mô hình AI nào có thể dùng Knowledge Setup?

Bất kỳ mô hình nào bạn kết nối trong TypingMind. Kỹ năng AI là các hướng dẫn bằng Markdown chứ không phải mã dành riêng cho từng nhà cung cấp, nên GPT, Claude, Gemini, Grok và các mô hình chạy trên thiết bị đều có thể tải kỹ năng này khi có yêu cầu phù hợp.

Bạn có thể dùng Knowledge Setup với bao nhiêu mô hình AI?

Bao nhiêu cũng được. Miễn là mô hình hỗ trợ kỹ năng, bạn có thể dùng Knowledge Setup với mô hình đó — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama và nhiều mô hình khác — tất cả đều trên TypingMind với khóa API riêng của bạn.

Kỹ năng AI Knowledge Setup có miễn phí không?

Có. Kỹ năng này được Cognigy phát hành trên GitHub theo giấy phép MIT. Bạn chỉ trả tiền cho nhà cung cấp AI của mình theo số token đã dùng.

Kỹ năng AI là gì?

Kỹ năng AI là một gói hướng dẫn có thể tái sử dụng, chỉ cho mô hình AI cách thực hiện một tác vụ cụ thể. Kỹ năng tuân theo định dạng mở Agent Skills: một tệp SKILL.md chứa tên và mô tả, cùng các tập lệnh, mẫu hoặc tệp tham khảo mà mô hình có thể cần. Mô hình chỉ đọc hướng dẫn khi yêu cầu của bạn phù hợp với kỹ năng, nên kỹ năng đã cài đặt không phát sinh chi phí cho đến khi được sử dụng.

Kỹ năng AI khác gì với plugin hoặc máy chủ MCP?

Plugin hoặc máy chủ MCP cung cấp cho mô hình các công cụ mới để gọi — mã được chạy ở đâu đó và trả về kết quả. Còn kỹ năng AI cung cấp kiến thức và quy trình: cách tiếp cận tác vụ, các bước cần thực hiện và tiêu chí của đầu ra tốt. Kỹ năng chỉ là nội dung Markdown, nên không cần máy chủ, khóa API hay môi trường thực thi và hoạt động với mọi mô hình.

Xem tất cả

Tạo ngay không gian làm việc AI riêng

Đăng ký bản tin của chúng tôi để nhận thông báo về tính năng mới và các đợt tặng quà sắp tới 👇