Installation
Requirements
- Python 3.8 or higher
Usage
Initialize the client
Memo Management
Create a Memo
Create a new memo that will be automatically processed (summarized, tagged, chunked, and indexed for search):title(string, max 255 chars) - The title of the memocontent(string) - The full content of the memo
metadata(dict) - Custom JSON metadatareference_id(string, max 255 chars) - An ID from your side that you can use to match Skald memo UUIDs with e.g. documents on your endtags(list of strings) - Tags for categorizationsource(string, max 255 chars) - An indication from your side of the source of this content, useful when building integrationsexpiration_date(string) - ISO 8601 timestamp for automatic memo expiration
Get a Memo
Retrieve a memo by its UUID or your reference ID:get_memo() method returns complete memo details including content, AI-generated summary, tags, and content chunks.
Memo Response Fields:
uuid- Unique identifier for the memotitle- Memo titlecontent- Full memo contentsummary- AI-generated summarypending- Boolean indicating if the memo is still being processedarchived- Boolean indicating if the memo is archivedtype- Memo type (“document” or “text”)metadata- Custom metadata objecttags- List of tag objectschunks- List of content chunk objects
List Memos
List all memos with pagination:page(int, optional) - Page number (default: 1)page_size(int, optional) - Results per page (default: 20, max: 100)
Update a Memo
Update an existing memo by UUID or reference ID:content field, the memo will be automatically reprocessed (summary, tags, and chunks regenerated).
Updatable Fields:
title(string)content(string)metadata(dict)client_reference_id(string)source(string)expiration_date(string)
Delete a Memo
Permanently delete a memo and all associated data:Check Memo Processing Status
After creating or updating a memo (especially when uploading files), it is automatically processed asynchronously (summarized, tagged, and chunked). Use thecheck_memo_status() method to check processing status:
memo_uuid- The memo’s UUIDstatus- Processing state: “processing”, “processed”, or “error”processing_started_at- ISO timestamp when processing startedprocessing_completed_at- ISO timestamp when processing completed (if finished)error_reason- Error message if status is “error”
File Uploads
Upload documents (PDF, DOC, DOCX, PPTX) to your Skald knowledge base. Files are automatically processed to extract text, then summarized, tagged, chunked, and indexed for search.Upload a Document
- PDF (
.pdf) - Microsoft Word (
.doc,.docx) - Microsoft PowerPoint (
.pptx)
file_path(string, required) - Path to the file to uploadmemo_data(dict, optional) - Optional metadata for the memo:title(string) - Title for the memosource(string) - Source system identifierreference_id(string) - Your external reference IDtags(list of strings) - Tags for categorizationmetadata(dict) - Custom JSON metadataexpiration_date(string) - ISO 8601 timestamp for automatic memo expiration
check_memo_status() to monitor processing progress.
Search Memos
Search through your memos using semantic search with optional filters:Search Parameters
query(string, required) - The search querylimit(integer, optional) - Maximum results to return (1-50, default 10)filters(list, optional) - List of filter objects to narrow results (see Filters section below)
Search Response
memo_uuid- Unique identifier for the memochunk_uuid- Unique identifier for the chunkmemo_title- Memo titlememo_summary- Auto-generated summary for the memocontent_snippet- A snippet containing content from the matching chunkdistance- A decimal from 0 to 2 determining how close the result was deemed to be to the query. The closer to 0 the more related the content is to the query.
Chat with Your Knowledge Base
Ask questions about your memos using an AI agent. The agent retrieves relevant context and generates answers with inline citations.Non-Streaming Chat
Streaming Chat
For real-time responses, use streaming chat:Chat Parameters
query(string, required) - The question to askfilters(list, optional) - List of filter objects to focus chat context on specific sources (see Filters section below)
Chat Response
Non-streaming responses include:ok(bool) - Success statusresponse(str) - The AI’s answerintermediate_steps(list) - Steps taken by the agent (for debugging)
{'type': 'token', 'content': str}- Each text token as it’s generated{'type': 'done'}- Indicates the stream has finished
Filters
Filters allow you to narrow down results based on memo metadata. You can filter by native fields or custom metadata fields. Filters are supported insearch(), chat(), and their streaming variants.
See Filters for complete documentation.
Filter Structure
Native Fields
Native fields are built-in memo properties:title- Memo titlesource- Source system (e.g., “notion”, “confluence”)client_reference_id- Your external reference IDtags- Memo tags (list)
Custom Metadata Fields
You can filter on any field from themetadata dict you provided when creating the memo.
Filter Operators
eq- Equals (exact match)neq- Not equalscontains- Contains substring (case-insensitive)startswith- Starts with prefix (case-insensitive)endswith- Ends with suffix (case-insensitive)in- Value is in list (requires list value)not_in- Value is not in list (requires list value)