chat2graph
chat2graph copied to clipboard
feat(agent): implement agentic text-to-GQL system with multi-stage wo…
…rkflow
https://github.com/TuGraph-family/chat2graph/issues/231
Implement comprehensive agentic text-to-graph query language system with context awareness, multi-stage validation, and self-optimization capabilities.
Core Components:
- DAL Layer: Query session, history, pattern, and feedback management (8 files)
- Service Layer: Context tools and query context service (2 files)
- Operators: 6 specialized operators for query lifecycle management
- Query intention analysis and validation
- Complexity analysis with index recommendations
- Path pattern recognition (multi-hop, temporal, spatial)
- Comprehensive query validation (schema, semantic, performance, security)
- Context enhancement with user preference learning
- Query design with optimization strategies
- Resources: Multi-hop reasoning, query planning, and validation (3 files)
- Workflow: Complete agentic text2gql configuration with 7-stage pipeline
- Testing: Comprehensive test suite (22 files: unit + integration)
- Unit tests for DAOs and services
- Integration tests for operator collaboration and workflows
Key Features:
- Multi-stage workflow: understand → analyze → enhance → design → validate → execute
- Context-aware query optimization with historical pattern learning
- Real-time validation (schema, semantic, performance, security)
- Support for complex patterns: multi-hop, temporal, spatial queries
- Self-validating agentic workflow with feedback loops
Title
Type
- [x]
feat: (new feature) - [ ]
fix: (bug fix) - [ ]
docs: (doc update) - [ ]
style: (update format) - [ ]
refactor: (refactor code) - [ ]
test: (test code) - [ ]
chore: (other updates)
Scope
- [x]
app: (Application Layer)- [ ]
web: (web front-end module) - [ ]
server: (web server module) - [x]
dal: (data access layer) - [ ]
sdk: (sdk module)
- [ ]
- [ ]
agent: (Agent Layer)- [x]
reasoner: (reasoner module) - [ ]
planner: (planner module) - [ ]
workflow: (workflow module) - [ ]
memory: (memory module) - [ ]
knowledge: (knowledge module) - [ ]
env: (env module) - [ ]
toolkit: (toolkit module)
- [x]
- [ ]
system: (System Layer)- [x]
plugin: (plugin module) - [ ]
tracer: (tracer module) - [ ]
resource: (resource module)
- [x]
- [ ]
none: (N/A)
Description
Issue: #
Checklist
- [x] I have prepared the pull request title according to the requirements.
- [x] I have successfully run all unit tests and integration tests.
- [x] I have followed the code style guidelines of this project.
- [x] I have already rebased the latest
masterbranch. - [x] I have commented my code, particularly in hard-to-understand areas.
- [x] I have made corresponding changes to the documentation.
#231