Feature/stt refine#103
Conversation
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 3 minutes and 52 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
Walkthrough내부 QA 실행 경로를 그래프 직접 호출에서 추적 가능한 래퍼( Changes
Sequence Diagram(s)sequenceDiagram
participant Client
participant QA_API as "app/api/qa.py"
participant Thread as "asyncio.to_thread"
participant Traced as "traced_internal_run\n(`@traceable`)"
participant Graph as "text_pipeline.graph.invoke"
Client->>QA_API: 내부 QA 요청
QA_API->>Thread: to_thread(traced_internal_run, initial_state)
Thread->>Traced: 실행
Traced->>Graph: graph.invoke(initial_state)
Graph-->>Traced: 결과(state)
Traced-->>Thread: 반환(state)
Thread-->>QA_API: 결과(state)
QA_API-->>Client: 응답 반환
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~30 minutes Possibly related PRs
시
🚥 Pre-merge checks | ✅ 1 | ❌ 2❌ Failed checks (1 warning, 1 inconclusive)
✅ Passed checks (1 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@app/api/websocket.py`:
- Line 346: The current join always uses a space: change the construction of
query so it uses an empty separator for CJK languages and a space otherwise —
e.g., determine sep = "" if last_lang_code in ("ja","zh") else " ", then set
query = (sep.join(final_parts) or last_interim).strip(); update the code around
variables final_parts, last_interim and last_lang_code (where query is assigned)
to use that language-aware separator.
In `@app/graph/nodes/classify/intent_gate.py`:
- Around line 74-80: The parsed JSON from llm.chat (variable parsed in
intent_gate.py) must be validated as a dict before using parsed.get(); modify
the logic in the block around raw = llm.chat(...) and parsed = json.loads(raw)
to: 1) catch json.JSONDecodeError/ValueError and route to the existing fallback
flow (e.g., set ranking=_DEFAULT_RANKING, place_category=None,
method="llm_fallback_invalid_json", error=str(e)); 2) if json.loads succeeds but
parsed is not a dict (e.g., list, string, null), treat that as an invalid schema
and perform the same fallback handling; and 3) only access
parsed.get("corrected_text") when isinstance(parsed, dict) to avoid
AttributeError and ensure fallback is used for malformed responses.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: ff52fdb0-e161-498f-b0d4-4b78dc10420c
📒 Files selected for processing (7)
app/api/qa.pyapp/api/websocket.pyapp/core/dependencies.pyapp/core/ws_stt_test.pyapp/graph/graph_builder.pyapp/graph/nodes/classify/intent_gate.pyaudio/m4a.py
💤 Files with no reviewable changes (2)
- app/graph/graph_builder.py
- audio/m4a.py
Summary by CodeRabbit
새로운 기능
개선사항
잡무(Chores)