You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Replaces the runtime path's ad-hoc println breadcrumb with Logging-based
structured records, and wires the previously-dormant VeriSimDB audit
path into every tool call.
- src/tools/observability.jl (new): correlation-id/tool-call-id minting,
order-independent argument hashing (never raw args), shape-only result
summaries (never raw values), configure_logging! (stderr ConsoleLogger,
level from STATISTIKLES_LOG_LEVEL, default Info), log_tool_call
(@info/@warn per tool call), and the audit-record construction +
record_audit! persistence wrapper (opt-in via
STATISTIKLES_AUDIT_PERSIST, off by default so nothing depends on a live
VeriSimDB backend).
- src/tools/lmstudio.jl: process_tool_calls now accepts/returns a
per-chat-turn correlation_id, times each tool call, and emits a
log_tool_call + record_audit! per call instead of the old
println("[symbolic] executing: ...").
- src/tools/chat.jl: mints one correlation_id per turn, threads it
through process_tool_calls and enforce_numeric_boundary! (including its
guardrail retry), and adds @warn/@error structured records alongside the
existing user-facing error messages (REPL stdout output is
unchanged/unpolluted — logs go to stderr only).
- src/tools/executor.jl: adds a @debug breadcrumb (off by default) in
the catch-all, carrying an argument hash rather than raw arguments.
- src/Statistikles.jl: `using Logging`, includes the new module, and
calls configure_logging! from __init__ (re-read every load, unlike
lmstudio.jl's precompiled BASE_URL const).
- Project.toml: declares the (already-transitive) Logging stdlib
dependency explicitly, matching the existing style for
Dates/Random/UUIDs/etc.
- test/observability_test.jl (new, wired into runtests.jl):
correlation-id uniqueness, argument-hash order-independence and
non-leakage, result-shape summaries, audit-record shape,
audit_persistence_enabled parsing, log-level parsing, and captured-log
assertions (Test.collect_test_logs) for both log_tool_call and
process_tool_calls end to end.
- QUICKSTART-MAINTAINER.adoc: documents STATISTIKLES_LOG_LEVEL and
STATISTIKLES_AUDIT_PERSIST.
Verification: full suite green under flock (WSL Debian, Julia 1.10.11) —
5710/5710 tests pass across all testsets, including the new 73-test
Observability suite. No MANOVA flake encountered.
<!--
SPDX-License-Identifier: CC-BY-SA-4.0
Copyright (c) Jonathan D.A. Jewell <j.d.a.jewell@open.ac.uk>
-->
## Summary
<!-- Briefly describe what this PR does and why. Link to related issues
with "Closes #N". -->
## Changes
<!-- List the key changes introduced by this PR. -->
-
## RSR Quality Checklist
<!-- Check all that apply. PRs that fail required checks will not be
merged. -->
### Required
- [ ] Tests pass (`just test` or equivalent)
- [ ] Code is formatted (`just fmt` or equivalent)
- [ ] Linter is clean (no new warnings or errors)
- [ ] No banned language patterns (no TypeScript, no npm/bun, no
Go/Python)
- [ ] No `unsafe` blocks without `// SAFETY:` comments
- [ ] No banned functions (`believe_me`, `unsafeCoerce`, `Obj.magic`,
`Admitted`, `sorry`)
- [ ] SPDX license headers present on all new/modified source files
- [ ] No secrets, credentials, or `.env` files included
### As Applicable
- [ ] `.machine_readable/STATE.a2ml` updated (if project state changed)
- [ ] `.machine_readable/ECOSYSTEM.a2ml` updated (if integrations
changed)
- [ ] `.machine_readable/META.a2ml` updated (if architectural decisions
changed)
- [ ] Documentation updated for user-facing changes
- [ ] `TOPOLOGY.md` updated (if architecture changed)
- [ ] `CHANGELOG` or release notes updated
- [ ] New dependencies reviewed for license compatibility (MPL-2.0 /
MPL-2.0)
- [ ] ABI/FFI changes validated (`src/abi/` and `ffi/zig/` consistent)
## Testing
<!-- Describe how you tested these changes. -->
## Screenshots
<!-- If applicable, add screenshots or terminal output demonstrating the
change. -->
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
0 commit comments