Course rag
Query the Software Engineering Economics course RAG service. Requires two arguments - token and question.From its SKILL.md
npx -y skills add No-99-Tongji/course-rag-plugin --skill course-ragAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
2 things to look at
- no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
- 3 stars3 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
2.0 KB, as published. Nobody here has run it
Course RAG Skill
Query the Software Engineering Economics course RAG service.
Required Arguments
This skill requires two arguments:
- token - The user's RAG access token (starts with
cr_) - question - The course question to query
Usage:
/course-rag token=cr_xxxxx What is software cost estimation?
If token or question is missing, prompt the user to provide both. Do not guess or fabricate.
Service URL
Configured via environment variable COURSE_RAG_BASE_URL, default: http://24.233.15.7:9000.
Workflow
- Parse
tokenandquestionfrom arguments. - If either is missing, ask the user to provide it.
- Connect to the RAG service:
curl -sS -X POST "$COURSE_RAG_BASE_URL/api/auth/connect" \
-H 'Content-Type: application/json' \
-d "{\"token\":\"$TOKEN\"}"
- If response contains
TOKEN_ALREADY_CONNECTED, tell the user the token is already connected and ask them to disconnect elsewhere or provide another token. - Save the returned
session_id. - Call the ask API:
curl -sS -X POST "$COURSE_RAG_BASE_URL/api/ask" \
-H 'Content-Type: application/json' \
-H "Authorization: Bearer $TOKEN" \
-H "X-Session-Id: $SESSION_ID" \
-d "{\"question\":\"$QUESTION\",\"top_k\":6}"
- Disconnect after the query:
curl -sS -X POST "$COURSE_RAG_BASE_URL/api/auth/disconnect" \
-H "Authorization: Bearer $TOKEN" \
-H "X-Session-Id: $SESSION_ID" >/dev/null
Response Style
- Answer in the user's language (default Chinese).
- Base the answer on the returned
answerandsourcesfields. - Include a concise "Sources" section listing the most relevant source titles and filenames.
- If the RAG service returns insufficient information, say that the course materials do not contain enough evidence.
- Do not claim information comes from the course unless it appears in the returned RAG result.