Academic Support — data source skill
You are reading the skill's own instructions. Everything you need to answer a question is in this folder and in the production read API; you need no local database.
Setup — once per machine
- Credentials live in
~/.claude/academic-support-api.env, never in this folder:
or, for someone with TimeBack admin access, their TimeBack client ID and secret instead of the key (or only a TimeBack access token, which they refresh themselves):ACADEMIC_SUPPORT_API_URL=<base URL of the read API, ending in /prod> ACADEMIC_SUPPORT_API_KEY=<the x-api-key issued to this person>
With the key, sendACADEMIC_SUPPORT_API_URL=<base URL of the read API, ending in /prod> TIMEBACK_CLIENT_ID=<their TimeBack client ID> TIMEBACK_CLIENT_SECRET=<their TimeBack client secret> # or TIMEBACK_TOKEN=<a TimeBack access token>x-api-key: <key>. With TimeBack credentials, read the same routes under{URL}/timeback/…and sendAuthorization: Basic base64(client_id:client_secret)(the API gets and refreshes the TimeBack token) orAuthorization: Bearer <token>(401 once it expires: get a new one). The credentials need TimeBack admin access (403 otherwise). If the file is missing, ask the person for the values, write the file with mode 600, and continue. - Check the pack:
python3 datasource/pack_check.py --quietmust end withAll pack checks passed.(offline; needs only Python 3). - Check the wire:
GET {URL}/health(no key) answers{"status":"ok"};GET {URL}/runswith the key (or{URL}/timeback/runswith TimeBack credentials) lists every loaded ledger day with itsrules_version,reader_versionandcode_commit.
Verify the install
python3 datasource/smoke.py — reads the latest served day and recomputes its headline figures (at risk, every category's students, the
exclusive owner split) from the student walk; the last line must be Smoke test passed. (N PASS). It proves the credentials work, the day names its
versions, and the wire's figures agree with the rules a reader applies. Run it after installing and whenever an answer looks wrong.
Reading order
- skill.json — the front door: what this is good for, when to reach for it, how to reach the wire, how to give feedback.
- DICTIONARY.md — the one dictionary. §§1–8 define every term in the business's words; §10 the ledger's columns; §10a the rules in the order that decides a row; §10b every figure on the page; §10c the read API as served (routes, parameters, shapes, errors, what is not served).
- ENABLEMENT.md — worked compositions. Composition 0 reads the ledger through the API; compositions 1–8 are the reference implementation's and run on its reference stores.
- BRAINLIFT.md — the opinion layer: what we believe about the data and why, with every dated ruling. Read it before disagreeing with a definition.
How to answer
- Name the day and the versions you read (
/runs:as_of_date,rules_version,reader_version). Two days are comparable only under the same rules version and reader. - Take figures from
/summary?as_of=<day>&scope=<scope>; check any figure by recounting it over/students(composition 0 shows how). Scopes:all,b:<brand>,y:<modality>,m:<brand · modality>,c:<campus_id>. - A category is a fact about a student × subject × day; a state (graduated, not started) is not a problem. Owners: system · investigate · guide (§10a step 10). "No one working on the problem" =
help_status = 'nobody'. - Say which kind a number is: a category is computed by the rules; a help status is a record match; an ask is a model reading (§13); hours are a model.
- Never write a student's name into anything that leaves the person's machine; use ids. Names travel to keyed readers only (§10c).
- If the documents and the wire disagree, the wire is the fact and the document has a defect: report it (below).
Giving feedback
File a report when the documents and the wire disagree, a figure cannot be reproduced from its rule, or a question this skill should answer cannot be. Anyone can file, with no key; the tracker is public, and each report is fixed where the data is born.
FEEDBACK=https://4cnfu40x26.execute-api.us-east-1.amazonaws.com/prod/feedback
curl -s "$FEEDBACK?state=open" # first: is it already reported? (the same title and body again within a day returns the first one, 200)
curl -s -X POST "$FEEDBACK" -H 'Content-Type: application/json' -d '{
"title": "P2 [data] <the field or figure, and what is wrong with it>",
"reporter": "<who or what is filing>",
"kind": "report",
"body": "From: <the question you were answering>\nProblem (dated evidence, counts or structure, never a person): <day, route, count, the rule it breaks>\nAsk: <the fix>\nAcceptance (a falsifiable test): <the query or recount that must pass>"
}' # 201 {number, url}
curl -s "$FEEDBACK/<number>" # the report, its state, and its resolution once closed
kind:report(a defect) orask(a question the skill should answer); title priority P0 (a wrong answer served now) · P1 (a real defect, workable) · P2 (minor).title,bodyandreporterare required (400 when missing); limits: title 200 characters, body 65,536, reporter 200 (413 over).- Evidence is a count, a field, a rule or a query. Never a student's name or an email address (such a report is refused, 422), and never a row that identifies a child: say what you found; do not paste student rows.
- The listing (
GET $FEEDBACK,?state=open|closed|all) is how you see the loop: a closed report carries its resolution.
Not in this pack
The production job's internal manual is not part of the pack, nor is the scheduled overnight processing that builds the reference ledger and pushes the Slack store; the skill reads the production API.