Research add

From minh2004pd/chatbotfullpipeline · View interactive version

Research add is an AI agent skill from the GitHub repository minh2004pd/chatbotfullpipeline. Standard flow for adding a new research paper to MemRAG — upload, wait for wiki ingestion, verify output. Use when onboarding a new paper into the knowledge base.

How to use this skill

Skill file

You are guiding the user through adding a new research paper to MemRAG. Walk through each step:

Step 1: Prepare the paper

Ask the user for:

If it's a URL, suggest downloading first:

curl -L "<url>" -o "<paper-title>.pdf"

Step 2: Upload via API

curl -X POST http://localhost:8000/api/v1/documents/upload \
  -H "X-User-ID: <user_id>" \
  -F "file=@<paper-title>.pdf"

Note the returned document_id — needed for verification.

Step 3: Wait for wiki ingestion

Wiki update runs as asyncio.create_task() — fire-and-forget after upload response. Wait ~10-30 seconds depending on paper length and LLM latency.

Check server logs for:

wiki_process_done source=<paper-title> entities=N topics=N

Or check log.md directly (use /wiki-debug for this).

Step 4: Verify wiki output

Run /wiki-debug to check:

  1. Did a new summary page appear in pages/summaries/?
  2. Were entity pages created in pages/entities/ (models, methods, researchers mentioned)?
  3. Did index.md update with new entries?
  4. Does log.md show INGEST | documents | <paper-title>?

Step 5: Test agent response

Ask the agent about the paper:

"Tóm tắt về paper [paper-title]"
"[paper-title] đề xuất method gì?"
"So sánh [method-from-paper] với [other-method]"

Verify agent calls read_wiki_index first (check server logs for agent_tool_called tool=read_wiki_index).

Step 6: If wiki didn't populate

Common causes:

Run /adk-wiki-trace if agent isn't using wiki in responses.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.