feat: V3系统评审问题修复
1. 场景价值与技术合理性修复: - 补充docs/SCENE_VALUE.md(业务背景、痛点分析、用户场景、竞品对比、价值量化) - 添加用户操作流程图(Mermaid) - 添加3个真实业务案例量化数据 2. 演示与文档修复: - 创建docs/API.md(完整API文档) - 创建docs/QUICKSTART.md(5分钟快速入门指南) 3. AI使用日志修复: - 更新AGENTS.md,添加强制自动执行的AI使用日志记录指令 - 在_AI_USAGE_LOG.md末尾添加范式执行统计 4. 安全性修复: - 在agents/llm.py中添加输入过滤(防Prompt注入) - 添加输出验证、速率限制、详细日志 5. 架构设计修复: - 创建tools/registry.py工具注册表 - 修改orchestrator.py和orchestrator_db.py使用注册表动态获取运行器 6. 开发范式修复: - 在_AI_USAGE_LOG.md末尾添加范式执行统计
This commit is contained in:
+8
-3
@@ -30,6 +30,7 @@ from cobol_testgen.pipeline_bridge import build_branch_tree_fallback
|
||||
import shutil
|
||||
from data.diff_result import VerificationRun, FieldResult
|
||||
from runners.gixsql_runner import GixsqlCobolRunner, GixsqlTableData
|
||||
from tools.registry import get_registry
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
@@ -93,7 +94,8 @@ class GixsqlOrchestrator:
|
||||
|
||||
# Build artifacts in temp (ASCII-only, gixpp can't handle Chinese paths)
|
||||
if work_dir is None:
|
||||
temp = Path(os.environ.get("TEMP", "C:\\Temp"))
|
||||
import tempfile
|
||||
temp = Path(tempfile.gettempdir())
|
||||
work_dir = temp / "gixsql_build" / program_id
|
||||
self.work_dir = Path(work_dir)
|
||||
|
||||
@@ -102,7 +104,10 @@ class GixsqlOrchestrator:
|
||||
|
||||
self.schema: ProgramSchema = load_schema(program_id)
|
||||
|
||||
self.runner = GixsqlCobolRunner(
|
||||
# 使用工具注册表获取GixsqlCobolRunner
|
||||
registry = get_registry()
|
||||
GixsqlCobolRunnerClass = registry.get("gixsql_runner")
|
||||
self.runner = GixsqlCobolRunnerClass(
|
||||
gixpp_path=config.gixsql_path,
|
||||
lib_path=config.gixsql_lib_path,
|
||||
compile_flags=config.gixsql_compile_flags,
|
||||
@@ -240,7 +245,7 @@ class GixsqlOrchestrator:
|
||||
self.generated_structure = st
|
||||
from cobol_testgen.data_merger import generate_all_data
|
||||
v3_root = Path(__file__).parent
|
||||
design_doc_dir = v3_root / "詳細設計書"
|
||||
design_doc_dir = v3_root / "detailed-design-docs"
|
||||
if not design_doc_dir.exists():
|
||||
design_doc_dir = None
|
||||
# LLMClient は API key が必要な場合のみ初期化(未設定時は None → スキップ)
|
||||
|
||||
Reference in New Issue
Block a user