Skip to content

Commit d8c1dcd

Browse files
authored
fix(core): address locate normalization review comments (#2703)
1 parent 64e5cd6 commit d8c1dcd

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

packages/core/src/ai-model/workflows/planning/locate-normalization.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,9 @@ export function normalizePlanningActionLocateFields(
3434
}
3535

3636
debug('actionInActionSpace matched', actionInActionSpace);
37-
const locateFields = actionInActionSpace
38-
? findAllMidsceneLocatorField(actionInActionSpace.paramSchema)
39-
: [];
37+
const locateFields = findAllMidsceneLocatorField(
38+
actionInActionSpace.paramSchema,
39+
);
4040

4141
debug('locateFields', locateFields);
4242

packages/core/tests/unit-test/locate-normalization.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ const locateResultContext = {
2424
};
2525

2626
describe('normalizePlanningActionLocateFields', () => {
27-
it('leaves actions unchanged when no action schema is available for locate normalization', () => {
27+
it('leaves actions unchanged when the planned action is outside the action space', () => {
2828
const adaptPlanningParamToPixelBbox = vi.fn();
2929
const actions: PlanningAction[] = [
3030
{

0 commit comments

Comments
 (0)