Skip to content

CLI の UX 磨き込み (search --json に score, show dump のフラグ, status のブロッキング, 接続リーク) #29

Description

@senna-lang

概要

エージェント/スクリプト利用時の細かな摩擦とリソースリーク。

詳細

  • search --json に score 欠落 search_cmd.py:60-72: 人間出力は score=... を出すが JSON に無い。エージェントが信頼度で閾値判断できない → "score": r.score を追加。
  • show dump が --distilled 必須 show_cmd.py:96-108: 唯一モードなのに必須フラグ = 純粋な摩擦。デフォルト化 or ガード撤去。
  • status が毎回 readiness をブロッキング status_cmd.py:41-46: check_ready が ollama/localhost:11434 をブロッキング。time-bound or --check オプトイン。
  • 接続リーク (error path): search_cmd.py context/_context_u1_u2、status_cmd.pyshow_cmd.py dump が try/finally 無しでエラー時に接続リーク。
  • (軽微) distill の "already running" が exit 0 (手動実行だと no-op で成功扱い)、index が init 無しで DB を作成しうる。

修正案

  • JSON に score を含める
  • show dump を distilled デフォルト化
  • readiness probe を time-bound/opt-in
  • 各コマンドの接続を try/finally で閉じる

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions