@model PlotLine.Models.ParagraphWorkspaceModel
@{
ViewData["Title"]="Manuscript structure and evidence";
var state=Model.State;
var scenePositions=state.Paragraphs.Where(p=>p.Story&&p.SceneId.HasValue).GroupBy(p=>p.SceneId!.Value).ToDictionary(g=>g.Key,g=>g.Min(p=>p.Occurrence.Ordinal));
var current=state.Scenes.Where(s=>!s.Retired).OrderBy(s=>scenePositions.GetValueOrDefault(s.Id,int.MaxValue)).ToArray();
var currentPage=Math.Clamp(Model.Page,1,Math.Max(1,(state.Paragraphs.Count+99)/100));
var evidencePage=Math.Clamp(Model.EvidencePage,1,Math.Max(1,(state.Evidence.Count+19)/20));
var rows=state.Paragraphs.Skip((currentPage-1)*100).Take(100).ToArray();
}
Preview feature: book backup and saved-point replacement are blocked for tracked books until paragraph evidence portability is qualified. Use isolated test books; keep your original Word document.
Word remains the source of your prose. These tools organise saved paragraphs and story evidence; they never edit your Word document.
@if(Model.Message!=null){
@Model.Message
}
@if(state.Paragraphs.Count==0){
Enable paragraph tracking
After completing a native manuscript import, adopt its accepted paragraph map. Existing unfinished imports are protected. No content is sent from Word by this action.
Some scene groupings need review. Their latest Word paragraphs are saved below; existing scene prose is retained until you confirm or adjust the grouping. Uncertain passages are not used as verified story evidence.
Save/reconnect mode explicitly permits manuscript updates from this book's associated Word document. Only changed prose is transmitted when the agent has a matching snapshot. It never starts AI analysis.
A different Word manuscript must be imported into a separate book. This preview never guesses evidence identity across documents.
Scenes
Split at a paragraph or move a boundary using the paragraph list. Move prose and reorder scenes in Word, then synchronise.
@foreach(var scene in current){var sceneIndex=Array.IndexOf(current,scene);var adjacent=sceneIndex+1@scene.Title @if(scene.NeedsRefinement){Needs refinement}