Skip to main content

Syntax

Description

The feedback relocate command updates the anchor location of a feedback entry when the original anchor has become stale or inaccurate due to spec changes. When you relocate feedback:
  • A new anchor is created at the specified line
  • The original location is preserved in anchor.original_location
  • Anchor status is set to "relocated"
  • The updated_at timestamp is updated
  • Changes are exported to JSONL
Use this command when:
  • Feedback shows as stale but content still exists in spec
  • Line numbers shifted due to spec edits
  • You know the correct new location for the feedback
  • Anchor needs manual correction
Relocation requires you to specify the correct line number. Review the spec content first to ensure accuracy.

Arguments

string
required
The feedback ID to relocateExample: FB-004The feedback entry whose anchor needs updating.

Options

number
required
New line number for the anchorExample: --line 50Must be a valid positive integer within the spec’s line range.

Examples

Relocate Stale Anchor

Fix a stale anchor by moving it to the correct line:

Relocate After Spec Edit

After adding content that shifted line numbers:
1

Check stale anchors

Shows FB-004 is stale at original line 38
2

View spec

Find that content is now at line 50
3

Relocate

Relocate Multiple Anchors

Fix several stale anchors:

Invalid Line Number

Attempt to relocate to invalid line:

Non-Existent Feedback

Attempt to relocate feedback that doesn’t exist:

JSON Output

Get machine-readable output:
Notice:
  • anchor_status is now "relocated"
  • original_location preserves the original line 38
  • New line_number is 50
  • updated_at timestamp reflects the relocation

What Happens During Relocation

1

Fetch spec content

The spec content is retrieved from the database
2

Create new anchor

A new anchor is generated at the specified line, including:
  • New line number
  • Updated section heading
  • New text snippet
  • Context before/after
3

Preserve original

Original location is saved in anchor.original_location:
  • Original line number
  • Original section heading
4

Set status

Anchor status is set to "relocated"
5

Update feedback

The feedback entry is updated in the database with new anchor
6

Update timestamp

updated_at is set to current time
7

Export to JSONL

Changes are written to feedback.jsonl

Understanding Relocated Status

After relocation, the feedback anchor has "relocated" status:

valid

Original anchor
  • Never moved
  • Content unchanged
  • No original_location
Color: Green

relocated

Manually updated
  • Moved to new line
  • Original preserved
  • Intentional update
Color: Yellow

stale

Needs attention
  • Content changed
  • Location uncertain
  • Requires relocation
Color: Red
The relocated status indicates:
  • The anchor was manually updated (not stale detection)
  • The original location is preserved for audit trail
  • The feedback is now accurately anchored

Common Workflows

Fix Stale Anchors

1

Find stale anchors

2

Review first stale feedback

Note the original line and content
3

View spec

Search for the content or section
4

Identify new line

Determine the correct line number where content now exists
5

Relocate

6

Verify

Check that status is “relocated” and location is correct

After Major Spec Update

1

Update spec

Make significant changes to specification
2

Check for stale anchors

3

Batch relocate

For each stale anchor:
4

Verify all fixed

Should show: ✓ No stale anchors found

Calculate New Line After Insertion

If you inserted 10 lines at line 20:

Interactive Relocation

Review and relocate interactively:

Scripting Examples

Bulk Relocate with Mapping

If you know the line number changes:

Calculate Offset Relocation

If all lines shifted by same amount:

Generate Relocation Plan

Finding the Correct Line

Method 1: Search by Snippet

Method 2: Search by Section

Method 3: Manual Review

Common Questions

Yes, you can relocate feedback multiple times. Each relocation updates the line number but preserves the original location from the first creation.
The original_location always refers to the first anchor location.
  1. Show the feedback to see the snippet:
  2. Search the spec for that content:
  3. Use the line number from grep output
No, relocation only changes the line number within the same spec. To move feedback to a different spec, you must:
  1. Dismiss the old feedback
  2. Create new feedback on the new spec
It always preserves the very first location where feedback was created, not intermediate relocations. This maintains the complete history.
Yes, technically you can relocate any feedback, not just stale ones. But it’s usually only necessary for stale anchors. Relocating a valid anchor would change its status to “relocated”.
Not directly. To undo:
However, the status will still show “relocated” not “valid”.

Troubleshooting

Cause: Line number is less than 1, not a number, or exceeds spec lengthSolution: Check spec length:
Ensure line number is within range:
Cause: The feedback ID doesn’t existSolution: List all feedback:
Use correct ID
Cause: The spec referenced by feedback doesn’t existSolution: This shouldn’t happen if feedback exists. Check database integrity:
Cause: Content at new line may not match expectedSolution: Verify the new location:
Status should be “relocated”, not “stale”. If still stale, you may have chosen wrong line.
Cause: Too many changes to accurately map old to new lineSolution: Consider dismissing old feedback and creating new:

feedback stale

Find stale anchors

feedback show

View feedback details

feedback dismiss

Dismiss feedback

spec show

View spec content

feedback list

List all feedback

Next Steps

1

Find stale anchors

2

Show feedback details

3

View spec

Find correct line number
4

Relocate

5

Verify

Check status is “relocated”

Feedback System Concept Guide

Learn more about the feedback system and anchor management