Rename Project concept to Novel across the stack
Renames the domain concept from Project to Novel throughout the backend (entities, DTOs, services, endpoints, ProjectAccessService/Permission, ProjectId foreign keys), MCP server (tool names and routes), and the React/Vite frontend (types, hooks, routes, components). Adds a new EF Core migration (RenameProjectToNovel) using RenameTable/RenameColumn to preserve existing data instead of dropping/recreating tables. Updates CLAUDE.md's structure section to reference Novels/ instead of Projects/.
This commit is contained in:
@@ -8,12 +8,12 @@ namespace Novelly.Mcp.Tools;
|
||||
public static class CharacterTools
|
||||
{
|
||||
[McpServerTool(Name = "list_characters")]
|
||||
[Description("List a project's character dossiers in full, including their relationships.")]
|
||||
[Description("List a novel's character dossiers in full, including their relationships.")]
|
||||
public static Task<CallToolResult> ListCharacters(
|
||||
NovelApiClient api,
|
||||
[Description("The project's id.")] Guid projectId,
|
||||
[Description("The novel's id.")] Guid novelId,
|
||||
CancellationToken ct) =>
|
||||
api.GetAsync($"/api/projects/{projectId}/characters", ct);
|
||||
api.GetAsync($"/api/novels/{novelId}/characters", ct);
|
||||
|
||||
[McpServerTool(Name = "get_character")]
|
||||
[Description("Read one character's dossier.")]
|
||||
@@ -24,11 +24,11 @@ public static class CharacterTools
|
||||
api.GetAsync($"/api/characters/{characterId}", ct);
|
||||
|
||||
[McpServerTool(Name = "create_character")]
|
||||
[Description("Add a character dossier to a project. Name is the only requirement — leave a field "
|
||||
[Description("Add a character dossier to a novel. Name is the only requirement — leave a field "
|
||||
+ "blank when the writer has not decided it yet rather than inventing detail.")]
|
||||
public static Task<CallToolResult> CreateCharacter(
|
||||
NovelApiClient api,
|
||||
[Description("The project's id.")] Guid projectId,
|
||||
[Description("The novel's id.")] Guid novelId,
|
||||
[Description("The character's name.")] string name,
|
||||
CancellationToken ct,
|
||||
[Description("Protagonist, Antagonist, Deuteragonist, Supporting, Minor, Mentor, LoveInterest or Foil.")]
|
||||
@@ -50,7 +50,7 @@ public static class CharacterTools
|
||||
[Description("Anything else worth recording.")] string? notes = null,
|
||||
[Description("Tags for cross-referencing. Unknown tags are created.")] string[]? tags = null,
|
||||
[Description("Other names this character is known by.")] string[]? aliases = null) =>
|
||||
api.PostAsync($"/api/projects/{projectId}/characters", new
|
||||
api.PostAsync($"/api/novels/{novelId}/characters", new
|
||||
{
|
||||
name,
|
||||
role = role ?? "Supporting",
|
||||
@@ -197,7 +197,7 @@ public static class CharacterTools
|
||||
api.PostAsync($"/api/arc-stages/{arcStageId}/beats", new { beatIds }, ct);
|
||||
|
||||
[McpServerTool(Name = "relate_characters")]
|
||||
[Description("Record a relationship between two characters in the same project. Creates both directions "
|
||||
[Description("Record a relationship between two characters in the same novel. Creates both directions "
|
||||
+ "at once — characterId's side and relatedCharacterId's side — so the pair always shows up "
|
||||
+ "on both dossiers.")]
|
||||
public static Task<CallToolResult> RelateCharacters(
|
||||
@@ -215,7 +215,7 @@ public static class CharacterTools
|
||||
|
||||
[McpServerTool(Name = "link_character_identity")]
|
||||
[Description("Record that this character is really another character — e.g. a character introduced "
|
||||
+ "under one name who is later revealed to be a character already in the project under "
|
||||
+ "under one name who is later revealed to be a character already in the novel under "
|
||||
+ "another name. Both characters keep their own dossier and beats; the canonical identity "
|
||||
+ "is whichever character you link to.")]
|
||||
public static Task<CallToolResult> LinkCharacterIdentity(
|
||||
|
||||
Reference in New Issue
Block a user