docs: fix drift in Health & Analytics - #320
Draft
jack-arturo wants to merge 1 commit into
Draft
Conversation
- /health always returns HTTP 200, never 503 - status is also degraded on sync_status drift_detected - queue_depth is enrichment_queue.qsize(), not pending + inflight - AUTOMEM_LOG_LEVEL does not exist; level is hardcoded INFO - repin source-note permalinks to automem@42ba8b6 Verified against automem@42ba8b61b7d0b24ecaeb7feb4ceef59f09fc7cd0 Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014iwvkKvNhquqnG4MQ6EEun
Deploying automem-website with
|
| Latest commit: |
df43df0
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://e3d58036.automem-website.pages.dev |
| Branch Preview URL: | https://docs-audit-reference-api-hea-8rcv.automem-website.pages.dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Automated docs-accuracy audit of
reference/api/health. First review of this page — no prior review state existed.The headline problem: the page told operators to alert on HTTP 503 from
/health. The endpoint never returns 503 —health()ends in a barereturn jsonify(health_data), so every response is HTTP 200 regardless of state. Any monitor wired to the documented contract would report the service healthy while both databases were down.HTTP 200/503health()returnsjsonify(health_data)with no status code — always HTTP 200. The string503does not appear anywhere inhealth.pystatusfield. Degradation table now shows 200 across the boardstatusis "degraded when Qdrant unavailable"sync_status == "drift_detected", i.e. both stores reachable but Qdrant holds fewer pointsqueue_depthis "Total jobs in queue (pending + inflight)"queue_depthisstate.enrichment_queue.qsize();pendingandinflightare lengths of two separate structures, computed independentlyqueue_depthas the queue size reported independently of the other twoAUTOMEM_LOG_LEVELenvironment variable:AUTOMEM_LOG_LEVEL=DEBUG"AUTOMEM_LOG_LEVELhas zero occurrences repo-wide (so does bareLOG_LEVEL).app.pycallsconfigure_logging(level=logging.INFO)with a hardcoded literal0720da242ba8b6; paths themselves all verified correctVerified against: automem@42ba8b61b7d0b24ecaeb7feb4ceef59f09fc7cd0
Questions
None.
Unverified
has_criticalin the/startup-recallresponse isany(importance >= 0.9). The page never defines the field, so there was nothing to correct — noting it here since the example payload happens to use exactly 0.9.Follow-ups
Beyond the 5-fix cap, left for a later pass:
vector_dimensions.mismatchboolean is computed ascollection_vector_size != VECTOR_SIZE— it compares the collection against the configured size, not theeffectiveprovider-reported size shown alongside it in the same object. The field table describes the object's members but not this comparison, which is worth spelling out./healthis exempt from auth insiderequire_api_token()(auth_helpers.pyL56-57), not via thebefore_requestpath list inapp.py(which exempts only OPTIONS,/viewer*, and/backup). The page's source note is correct; the distinction may still be worth a sentence.Generated by Claude Code