Sync: add semantic index and lsp notes

This commit is contained in:
2026-04-25 09:09:38 +08:00
parent 480d64ae81
commit 466273a164
13 changed files with 1158 additions and 32 deletions

View File

@@ -0,0 +1,39 @@
---
title: "Intelephense"
type: entity
tags: [language-server, php]
sources: [lsp-index-engineer]
last_updated: 2026-04-25
---
## Definition
Intelephense 是 PHP 语言的主流 Language Server Protocol 实现,提供高性能的 PHP 代码智能功能,包括跳转到定义、查找引用、悬停文档、符号导航等。
## Usage in LSP/Index Engineer
LSP/Index Engineer 的 graphd 系统通过以下方式使用 Intelephense
```typescript
const phpClient = new LanguageClient('php', {
command: 'intelephense',
args: ['--stdio'],
rootPath: projectRoot
});
```
## Known Limitations
Intelephense 与 TypeScript Language Server 相比:
- 不支持层级符号Hierarchical Symbols
- PHP 的命名空间和类结构解析有差异
- LSP/Index Engineer 在 graphd 中需要针对这些差异进行适配处理
## Note
TypeScript 和 PHP 支持是 LSP/Index Engineer 的**默认要求**必须首先达到生产就绪状态。PHP 优先使用 Intelephense也可选择 phpactor 作为替代。
## Aliases
- intelephense
- PHP Language Server
- PHP LSP

35
wiki/entities/LSIF.md Normal file
View File

@@ -0,0 +1,35 @@
---
title: "LSIF"
type: entity
tags: [code-intelligence, index-format, exchange]
sources: [lsp-index-engineer]
last_updated: 2026-04-25
---
## Definition
LSIFLanguage Server Index Format是一种预计算语义数据的标准化交换格式允许在不运行语言服务器的情况下直接加载代码索引数据。
## Purpose
LSIF 解决了以下问题:
- 语言服务器启动慢 → 直接加载预计算索引
- 协作场景 → 团队成员共享索引而非各自运行 LSP
- CI/CD → 在流水线中预先生成索引
- 跨平台 → 不同编辑器共享同一索引源
## Usage in LSP/Index Engineer
LSP/Index Engineer 的语义索引基础设施支持 LSIF 导入/导出:
- 导入:加载预先生成的 LSIF 数据,零延迟启动
- 导出:将 nav.index.jsonl 数据导出为 LSIF 格式
## Relationship to nav.index.jsonl
LSIF 和 nav.index.jsonl 相互补充:
- LSIF用于交换和分发的标准化格式
- nav.index.jsonlLSP/Index Engineer 的内部流式索引格式
## Aliases
- Language Server Index Format
- LSIF

View File

@@ -1,40 +1,37 @@
---
title: "The Agency"
type: entity
tags: [multi-agent, open-source, ai-agents]
sources: [contributing, contributing_zh-cn, specialized-workflow-architect, agentic-identity-trust, specialized-document-generator, government-digital-presales-consultant, healthcare-marketing-compliance, specialized-civil-engineer, specialized-cultural-intelligence-strategist]
tags: [multi-agent, organization, specialized]
sources: [lsp-index-engineer, corporate-training-designer, specialized-cultural-intelligence-strategist, specialized-model-qa, specialized-workflow-architect]
last_updated: 2026-04-25
---
## Definition
The Agency 是一个开源的多智能体Multi-Agent系统提供了 147 个专业 Agent涵盖 12 个业务部门Engineering、Design、Finance、Game Dev、Marketing、Paid Media、Product、Project Management、Testing、Support、Spatial Computing、Specialized。
## Structure
The Agency 是一个多智能体Multi-Agent系统组织框架提供 147 个专业化 Agent跨 12 个业务部门覆盖工程Engineering、设计Design、金融Finance、游戏开发Game Dev、营销Marketing、付费媒体Paid Media、产品Product、项目管理Project Management、测试Testing、支持Support、空间计算Spatial Computing和专业化Specialized
### Departments
| 部门 | 职能 | 代表 Agent |
|------|------|-----------|
| Specialized | 垂直领域专家 | [[Cultural Intelligence Strategist]]、Civil Engineer、Document Generator |
| Engineering | 软件开发 | Backend Architect、Reality Checker、API Tester |
| Design | 视觉与体验设计 | [[ArchitectUX]]、Brand Guardian、UX Researcher |
| Project Management | 项目组合管理 | Studio Producer、Senior PM、Jira Workflow Steward |
| Spatial Computing | XR/AR/VR | XR Interface Architect、visionOS Engineer |
| Paid Media | 广告投放 | PPC Strategist、Programmatic Buyer |
| Marketing | 内容与增长 | Content Creator、Growth Hacker |
| Product | 产品策略 | Product Manager、Trend Researcher |
| Testing | 质量保障 | Accessibility Auditor、Performance Benchmarker |
| Support | 客户支持 | Support Responder、Analytics Reporter |
## Key Characteristics
### Core Principles
- **鲜明性格**:每个 Agent 都有明确的个性,而非泛化的人设
- **明确交付物**:真实代码、模板、量化指标
- **可验证工作流**:经过实践检验的操作流程
- **学习与记忆**:持续更新领域知识
- **Agent 设计五原则**:鲜明性格(拒绝通用人设)、明确交付物(真实代码/模板)、可量化指标、经过验证的工作流、学习记忆机制
- **协作模式**Agent 间通过交接合同Handoff Contract进行确定性状态传递
- **Specialized 部门**:包含 9 个专业化 Agent见下方列表专注于特定领域的深度专业知识
## Key Files
- `Agent/agency-agents/`:所有 Agent 定义文件
- `SPEC.md`Agent 设计规范
## Agent Collaboration Protocol
## Related
- [[Multi-Agent-System-Reliability]]The Agency 的可靠性架构模式
- [[Multi-Agent-Team]]:多 Agent 团队配置最佳实践
标准协作链Reality Checker 验证 → Backend Architect 实现 → API Tester 生成测试用例 → DevOps Automator 验证清理顺序。Workflow Architect 在此体系中提供工作流建模能力LSP/Index Engineer 提供代码语义基础设施。
## Specialized Department Agents
1. **LSP/Index Engineer** — LSP 客户端编排和语义索引基础设施专家
2. **Model QA Specialist** — ML/统计模型的端到端独立审计专家
3. **Corporate Training Designer** — 企业培训体系架构师
4. **Cultural Intelligence Strategist** — 文化包容性专家
5. **Workflow Architect** — 工作流设计专家
6. **Identity & Trust Architect** — Agentic 身份与信任架构专家
7. **Automation Governance Architect** — 自动化治理架构师
8. **Government Digital Presales Consultant** — 政府数字化售前顾问
9. **Document Generator Agent** — 文档生成 Agent
## Value
The Agency 的核心价值在于将复杂任务分解为专业化 Agent 协作,每个 Agent 拥有鲜明的人设、明确的交付物和可量化的成功指标,避免了通用 LLM 的"万事通但样样松"问题。

View File

@@ -0,0 +1,41 @@
---
title: "TypeScript Language Server"
type: entity
tags: [language-server, typescript, javascript]
sources: [lsp-index-engineer]
last_updated: 2026-04-25
---
## Definition
TypeScript Language Server 是 TypeScript/JavaScript 的官方 Language Server Protocol 实现,提供代码补全、跳转到定义、查找引用、悬停文档、符号导航等代码智能功能。
## Usage in LSP/Index Engineer
LSP/Index Engineer 的 graphd 系统通过以下方式使用 TypeScript Language Server
```typescript
const tsClient = new LanguageClient('typescript', {
command: 'typescript-language-server',
args: ['--stdio'],
rootPath: projectRoot
});
```
## Key Capabilities
- 符号层级Symbol Hierarchy
- 跳转到定义Go-to-Definition
- 查找所有引用Find All References
- 悬停文档Hover Documentation
- 自动补全Auto-completion
- 代码格式化Code Formatting
## Note
TypeScript 和 PHP 支持是 LSP/Index Engineer 的**默认要求**,必须首先达到生产就绪状态。
## Aliases
- typescript-language-server
- tsserver
- ts-language-server