Repository navigation
A local Spark-to-Plannotator review loop: feedback, approval, dismissal, and strict exit codes #3335
FenjuFu
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
A CSV export plan can sound reasonable and still omit the cases that make it safe to implement. The first local model output proposed
csv.reader→csv.writer, but gave no explicit tests for empty input, embedded newlines, or row order.I connected Plannotator to Spark-X2.6-1.7B GGUF, served on CPU with llama.cpp. The useful result was a complete local review round trip: a browser comment became structured feedback, the unchanged feedback went into a second model request, and the revised plan opened for another decision. No coding-agent process was needed.
The integration detail that mattered: with
--gate --json --require-approval, both feedback and dismissal exit 1. A caller must inspectdecision; treating every nonzero exit as a crash would lose the feedback, while treating an ordinary exit as approval would be unsafe.What actually ran
This was a scripted review harness operating the real Plannotator browser UI. The comment, Send Feedback, and Approve controls were exercised against the released executable; approvals below test the decision transport. The CSV implementation itself was not executed.
annotated, complete feedback textapproveddismissedFile not foundThe close case discarded a setup draft whose quote had been changed by shell escaping. It was never sent to the model; the final feedback run used a fresh copy of the original model output and the unambiguous wording below.
The final global comment was:
Plannotator returned
decision: "annotated"and afeedbackstring headed# File Feedback, containing that comment. I passed the whole returned string back to Spark as the next user message, together with the original conversation and model response; neither model plan was hand-edited.The second output added “Explicitly test empty input, embedded newlines, and row order” and specified
newline=''for the input file. It still left the output file's newline option unspecified, and named tests without concrete fixtures or expected results. The loop delivered the feedback; it did not establish that the proposed implementation was correct.Versions and setup
b2eb7d6931106ceea5454f788a00f21a7bf34bf1. The standalone Windows binary matched its official SHA256 sidecar:f94fc8be8600159eedb33e1201da4d9e47bc977e7da565bb0310f83d1a3e8747.cfb9d4b754616ca47d165fa1ff8a7a80c30847e3.Spark-X2.6-1.7B-Q4_K_M.gguf, model revisionc4bc25be0e537d55266d90a08bdef931f4cf580a(Apache-2.0 model card). Reverified cached weight SHA256:7abd9859c10924be3c583945456fa9b25d0569484876105a7b7376f7938fffb7.stop.I used the official standalone release, rather than installing agent hooks or modifying an existing coding-agent configuration. Start the model server in a separate terminal, with the pinned model file available locally:
Minimal local review loop
Save this as
minimal.pyin a fresh writable directory. It uses only Python's standard library. In the first review, add the comment above and press Send Feedback; in the second review, inspect the revision and choose an outcome. It preserves non-approval outcomes rather than treating them as permission to execute anything.The central command exercised was:
For the boundary check, the same strict flags with
absent-plan.mdproduced exit 2 and no decision file. For dismissal I read the currentserverSessionfrom/api/planand posted to/api/exit?serverSession=...on that same loopback review server.What this establishes, and what remains open
The model requests returned HTTP 200. Initial generation took 39.78 s (74 input / 198 output tokens); feedback revision took 83.20 s (366 input / 245 output tokens). These are single request durations including prompt processing and decoding, excluding model loading and review time; different prompt sizes and separate server starts make them unsuitable for a speed comparison.
The practical outcome is a small local adapter that can distinguish a requested revision from approval and dismissal, then bring a revised document back into the review UI. This is one task with one feedback round, not an evaluation of model quality or CSV performance. No CSV code, memory benchmark, implementation tests, production deployment, agent hooks, or built-in Ask AI integration was tested. The output-file newline omission and the absence of concrete test cases still need a further review before implementation.
All managed review files were isolated under the experiment directory. Sharing and built-in AI features were disabled; the browser used real UI screenshots without visual reconstruction. Local document/model handling here does not imply that Plannotator makes no network requests: its normal release checking is a separate behavior.
All reactions