feat(core): support scoped AI contexts and stateless Test Runner workflows - #3065
Merged
Conversation
Deploying midscene with
|
| Latest commit: |
bf1ea41
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://ec67973a.midscene.pages.dev |
| Branch Preview URL: | https://fix-test-ai-act-context-hist.midscene.pages.dev |
xiong35
force-pushed
the
fix/test-ai-act-context-history
branch
from
August 31, 2026 07:38
08ad708 to
f353fae
Compare
xiong35
force-pushed
the
fix/test-ai-act-context-history
branch
from
September 1, 2026 06:53
44fdb31 to
e7aa68c
Compare
xiong35
force-pushed
the
fix/test-ai-act-context-history
branch
from
September 2, 2026 09:35
e7aa68c to
88c6693
Compare
xiong35
force-pushed
the
fix/test-ai-act-context-history
branch
from
September 4, 2026 03:57
88c6693 to
9a2880e
Compare
EAGzzyCSL
approved these changes
Sep 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
options.context > aiContexts[apiName] > aiContexts.default.setAIContext()for updating the default or an API-specific context.aiActContextcompatibility APIs.Context resolution
Only the highest-priority defined context is used:
options.contextaiContexts[apiName]aiContexts.defaultContexts are not merged automatically.
''explicitly clears lower-priority context.undefinedfalls back to the next configured level.The selected context remains raw in task and report data and is wrapped in a generic
<CONTEXT>block only when building the LLM input.Backward compatibility
aiActContextandaiActionContextremain available as deprecated aliases foraiContexts.aiAct.setAIActContext()andsetAIActionContext()remain available as deprecated aliases forsetAIContext('aiAct', context).aiContexts.aiActare provided,aiContexts.aiActtakes precedence.Test Runner behavior
ctx.history,NodeHistoryEntry, workflow history accumulation, and automatic history injection.aiActcall remains unchanged.Validation
pnpm run lintpnpm run type-check:testspnpm exec nx run-many -t build -p @midscene/core @midscene/test --parallel=2pnpm exec nx run-many -t test -p @midscene/core @midscene/shared @midscene/test @midscene/android --parallel=3pnpm --filter @midscene/test exec vitest --run --config vitest.e2e.config.ts