Skip to main content
Glama
GraphModels.cs1.76 kB
namespace CentralMemoryMcp.Functions.Models { /// <summary> /// Entity in the knowledge graph. /// Table: entities /// PartitionKey: WorkspaceName (groups all entities in a workspace) /// RowKey: Id (Guid) - stable, avoids special character issues in names /// </summary> public record EntityModel(string WorkspaceName, string Name, string EntityType, List<string> Observations, string? Metadata = null) { public Guid Id { get; internal set; } = Guid.NewGuid(); public string PartitionKey => WorkspaceName; public string RowKey => Id.ToString("N"); // compact guid without dashes } /// <summary> /// Relation between entities in the knowledge graph. /// Table: relations /// PartitionKey: WorkspaceName (groups all relations in a workspace for partition scalability) /// RowKey: Id (Guid) - stable unique relation identifier /// </summary> public record RelationModel(string WorkspaceName, Guid FromEntityId, Guid ToEntityId, string RelationType, string? Metadata = null) { public Guid Id { get; internal set; } = Guid.NewGuid(); public string PartitionKey => WorkspaceName; public string RowKey => Id.ToString("N"); } /// <summary> /// Workspace metadata. /// Table: workspaces /// PartitionKey: "workspaces" (all workspaces in single partition for listing) /// RowKey: WorkspaceName (unique workspace identifier) /// </summary> public record WorkspaceModel(string Name, string? Description = null, DateTime? CreatedAt = null) { public Guid Id { get; internal set; } = Guid.NewGuid(); public string PartitionKey => "workspaces"; public string RowKey => Name.ToLowerInvariant(); } }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/MWG-Logan/Central-Memory-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server