UNPKG

atlas-mcp-server

Version:

ATLAS (Adaptive Task & Logic Automation System): An MCP server enabling LLM agents to manage projects, tasks, and knowledge via a Neo4j-backed, three-tier architecture. Facilitates complex workflow automation and project management through LLM Agents.

88 lines (87 loc) 3.51 kB
import { KnowledgeFilterOptions, Neo4jKnowledge, PaginatedResult } from "./types.js"; /** * Service for managing Knowledge entities in Neo4j */ export declare class KnowledgeService { /** * Add a new knowledge item * @param knowledge Input data, potentially including domain and citations for relationship creation * @returns The created knowledge item, including its domain and citations. */ static addKnowledge(knowledge: Omit<Neo4jKnowledge, "id" | "createdAt" | "updatedAt"> & { id?: string; domain?: string; citations?: string[]; }): Promise<Neo4jKnowledge & { domain: string | null; citations: string[]; }>; /** * Link two knowledge items with a specified relationship type. * @param sourceId ID of the source knowledge item * @param targetId ID of the target knowledge item * @param relationshipType The type of relationship to create (e.g., 'RELATED_TO', 'IS_SUBTOPIC_OF') - Validation needed * @returns True if the link was created successfully, false otherwise */ static linkKnowledgeToKnowledge(sourceId: string, targetId: string, relationshipType: string): Promise<boolean>; /** * Get a knowledge item by ID, including its domain and citations via relationships. * @param id Knowledge ID * @returns The knowledge item with domain and citations added, or null if not found. */ static getKnowledgeById(id: string): Promise<(Neo4jKnowledge & { domain: string | null; citations: string[]; }) | null>; /** * Update a knowledge item, including domain and citation relationships. * @param id Knowledge ID * @param updates Updates including optional domain and citations * @returns The updated knowledge item (without domain/citations properties) */ static updateKnowledge(id: string, updates: Partial<Omit<Neo4jKnowledge, "id" | "projectId" | "createdAt" | "updatedAt">> & { domain?: string; citations?: string[]; }): Promise<Neo4jKnowledge>; /** * Delete a knowledge item * @param id Knowledge ID * @returns True if deleted, false if not found */ static deleteKnowledge(id: string): Promise<boolean>; /** * Get knowledge items for a project with optional filtering and server-side pagination. * Returns domain and citations via relationships. * @param options Filter and pagination options * @returns Paginated list of knowledge items including domain and citations */ static getKnowledge(options: KnowledgeFilterOptions): Promise<PaginatedResult<Neo4jKnowledge & { domain: string | null; citations: string[]; }>>; /** * Get all available domains with item counts * @returns Array of domains with counts */ static getDomains(): Promise<Array<{ name: string; count: number; }>>; /** * Get all unique tags used across knowledge items with counts * @param projectId Optional project ID to filter tags * @returns Array of tags with counts */ static getTags(projectId?: string): Promise<Array<{ tag: string; count: number; }>>; /** * Add CITES relationships from a knowledge item to new Citation nodes. * @param knowledgeId Knowledge ID * @param citations Array of citation source strings * @returns The IDs of the created Citation nodes * @private */ private static addCitations; }