tools

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 29, 2026 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Analyze

type Analyze struct {
	// contains filtered or unexported fields
}

Analyze implements graph analysis MCP tools.

func NewAnalyze

func NewAnalyze(c *client.Client) *Analyze

NewAnalyze creates a new Analyze tool handler.

func (*Analyze) FindConnections

func (a *Analyze) FindConnections(ctx context.Context, req *mcp.CallToolRequest, input types.FindConnectionsInput) (*mcp.CallToolResult, any, error)

FindConnections finds how two pages are connected in the graph.

func (*Analyze) GraphOverview

func (a *Analyze) GraphOverview(ctx context.Context, req *mcp.CallToolRequest, input types.GraphOverviewInput) (*mcp.CallToolResult, any, error)

GraphOverview returns global graph statistics.

func (*Analyze) KnowledgeGaps

func (a *Analyze) KnowledgeGaps(ctx context.Context, req *mcp.CallToolRequest, input types.KnowledgeGapsInput) (*mcp.CallToolResult, any, error)

KnowledgeGaps finds sparse areas in the knowledge graph.

func (*Analyze) TopicClusters

func (a *Analyze) TopicClusters(ctx context.Context, req *mcp.CallToolRequest, input types.TopicClustersInput) (*mcp.CallToolResult, any, error)

TopicClusters finds community clusters in the knowledge graph.

type Flashcard

type Flashcard struct {
	// contains filtered or unexported fields
}

Flashcard implements flashcard/SRS MCP tools.

func NewFlashcard

func NewFlashcard(c *client.Client) *Flashcard

NewFlashcard creates a new Flashcard tool handler.

func (*Flashcard) FlashcardCreate

func (f *Flashcard) FlashcardCreate(ctx context.Context, req *mcp.CallToolRequest, input types.FlashcardCreateInput) (*mcp.CallToolResult, any, error)

FlashcardCreate creates a new flashcard (block with #card tag and child answer).

func (*Flashcard) FlashcardDue

FlashcardDue returns cards currently due for review.

func (*Flashcard) FlashcardOverview

func (f *Flashcard) FlashcardOverview(ctx context.Context, req *mcp.CallToolRequest, input types.FlashcardOverviewInput) (*mcp.CallToolResult, any, error)

FlashcardOverview returns SRS statistics across all cards.

type Journal

type Journal struct {
	// contains filtered or unexported fields
}

Journal implements journal MCP tools.

func NewJournal

func NewJournal(c *client.Client) *Journal

NewJournal creates a new Journal tool handler.

func (*Journal) JournalRange

func (j *Journal) JournalRange(ctx context.Context, req *mcp.CallToolRequest, input types.JournalRangeInput) (*mcp.CallToolResult, any, error)

JournalRange returns journal entries across a date range.

func (*Journal) JournalSearch

func (j *Journal) JournalSearch(ctx context.Context, req *mcp.CallToolRequest, input types.JournalSearchInput) (*mcp.CallToolResult, any, error)

JournalSearch searches within journal entries.

type Navigate struct {
	// contains filtered or unexported fields
}

Navigate implements navigation MCP tools.

func NewNavigate

func NewNavigate(c *client.Client) *Navigate

NewNavigate creates a new Navigate tool handler.

GetBlock retrieves a block with ancestors, children, and optionally siblings.

GetLinks returns forward links and backlinks for a page.

GetPage retrieves a page with its full recursive block tree and parsed content.

func (n *Navigate) GetReferences(ctx context.Context, req *mcp.CallToolRequest, input types.GetReferencesInput) (*mcp.CallToolResult, any, error)

GetReferences finds all blocks referencing a specific block via ((uuid)).

ListPages lists pages with optional filtering.

Traverse finds paths between two pages using BFS on the link graph.

type Search struct {
	// contains filtered or unexported fields
}

Search implements search and query MCP tools.

func NewSearch

func NewSearch(c *client.Client) *Search

NewSearch creates a new Search tool handler.

func (*Search) FindByTag

func (s *Search) FindByTag(ctx context.Context, req *mcp.CallToolRequest, input types.FindByTagInput) (*mcp.CallToolResult, any, error)

FindByTag finds content by tag, including child tags.

func (*Search) QueryDatalog

func (s *Search) QueryDatalog(ctx context.Context, req *mcp.CallToolRequest, input types.QueryDatalogInput) (*mcp.CallToolResult, any, error)

QueryDatalog executes raw DataScript queries.

func (*Search) QueryProperties

func (s *Search) QueryProperties(ctx context.Context, req *mcp.CallToolRequest, input types.QueryPropertiesInput) (*mcp.CallToolResult, any, error)

QueryProperties finds blocks/pages by property values.

func (*Search) Search

Search performs full-text search across all blocks with context.

type Whiteboard

type Whiteboard struct {
	// contains filtered or unexported fields
}

Whiteboard implements whiteboard MCP tools.

func NewWhiteboard

func NewWhiteboard(c *client.Client) *Whiteboard

NewWhiteboard creates a new Whiteboard tool handler.

func (*Whiteboard) GetWhiteboard

GetWhiteboard retrieves a whiteboard's content including embedded pages and connections.

func (*Whiteboard) ListWhiteboards

ListWhiteboards returns all whiteboards in the graph.

type Write

type Write struct {
	// contains filtered or unexported fields
}

Write implements write MCP tools.

func NewWrite

func NewWrite(c *client.Client) *Write

NewWrite creates a new Write tool handler.

func (*Write) CreatePage

func (w *Write) CreatePage(ctx context.Context, req *mcp.CallToolRequest, input types.CreatePageInput) (*mcp.CallToolResult, any, error)

CreatePage creates a new page with optional properties and initial blocks.

func (*Write) DeleteBlock

func (w *Write) DeleteBlock(ctx context.Context, req *mcp.CallToolRequest, input types.DeleteBlockInput) (*mcp.CallToolResult, any, error)

DeleteBlock removes a block from the graph.

func (*Write) LinkPages

func (w *Write) LinkPages(ctx context.Context, req *mcp.CallToolRequest, input types.LinkPagesInput) (*mcp.CallToolResult, any, error)

LinkPages creates bidirectional links between two pages.

func (*Write) MoveBlock

func (w *Write) MoveBlock(ctx context.Context, req *mcp.CallToolRequest, input types.MoveBlockInput) (*mcp.CallToolResult, any, error)

MoveBlock moves a block to a new location.

func (*Write) UpdateBlock

func (w *Write) UpdateBlock(ctx context.Context, req *mcp.CallToolRequest, input types.UpdateBlockInput) (*mcp.CallToolResult, any, error)

UpdateBlock updates an existing block's content.

func (*Write) UpsertBlocksRaw

func (w *Write) UpsertBlocksRaw(ctx context.Context, req *mcp.CallToolRequest) (*mcp.CallToolResult, error)

UpsertBlocksRaw is the raw ToolHandler for upsert_blocks (avoids recursive type cycle in schema generation).

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL