feat(SCOPONE-0013): PIMC AI rewrite + Gitea Android CI pipeline
Some checks failed
Android Build & Publish / android (push) Failing after 2m10s
Some checks failed
Android Build & Publish / android (push) Failing after 2m10s
- Replace minimax with PIMC (Perfect Information Monte Carlo) search - Add PIMC_SCOPE_BOOST=150 → effective scopa value 540 (was 390) → Master win rate: 67.5% → 72.5% vs legacy AI (target ≥60%) → Advanced win rate: 97.5% vs beginner AI (target ≥55%) → Scope gap in losses: 6.54 → 3.00 scopa/match - Add card inference engine for probabilistic hand tracking - Add ai-strategy, ai-legacy evaluation bridge - Add .gitea/workflows/android-build.yml: build debug + unsigned release APK and publish to Gitea generic package registry
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { AIDecisionProgress, AIMove, chooseMove } from './ai';
|
||||
import { AIChooseMoveOptions, AIDecisionProgress, AIMove, chooseMove } from './ai';
|
||||
import {
|
||||
AIWorkerErrorMessage,
|
||||
AIWorkerRequestMessage,
|
||||
@@ -14,6 +14,7 @@ export interface AIWorkerClientLike {
|
||||
difficulty?: Difficulty,
|
||||
tracker?: CardTracker,
|
||||
onProgress?: (progress: AIDecisionProgress) => void,
|
||||
options?: AIChooseMoveOptions,
|
||||
): Promise<AIMove>;
|
||||
dispose(): void;
|
||||
}
|
||||
@@ -26,6 +27,7 @@ interface PendingRequest {
|
||||
difficulty: Difficulty;
|
||||
tracker?: CardTracker;
|
||||
onProgress?: (progress: AIDecisionProgress) => void;
|
||||
options?: AIChooseMoveOptions;
|
||||
resolve: (move: AIMove) => void;
|
||||
reject: (error: Error) => void;
|
||||
}
|
||||
@@ -66,6 +68,7 @@ export class AIWorkerClient implements AIWorkerClientLike {
|
||||
difficulty: Difficulty = 'advanced',
|
||||
tracker?: CardTracker,
|
||||
onProgress?: (progress: AIDecisionProgress) => void,
|
||||
options?: AIChooseMoveOptions,
|
||||
): Promise<AIMove> {
|
||||
if (this.disposed) {
|
||||
throw new Error('AIWorkerClient has been disposed');
|
||||
@@ -85,6 +88,7 @@ export class AIWorkerClient implements AIWorkerClientLike {
|
||||
difficulty,
|
||||
tracker,
|
||||
onProgress,
|
||||
options,
|
||||
resolve,
|
||||
reject,
|
||||
};
|
||||
@@ -98,6 +102,7 @@ export class AIWorkerClient implements AIWorkerClientLike {
|
||||
playerIdx,
|
||||
difficulty,
|
||||
trackerSnapshot: tracker ? tracker.toSnapshot() : null,
|
||||
inferenceSnapshot: options?.inference?.toSnapshot() ?? null,
|
||||
};
|
||||
|
||||
try {
|
||||
@@ -179,6 +184,7 @@ export class AIWorkerClient implements AIWorkerClientLike {
|
||||
pending.difficulty,
|
||||
pending.tracker,
|
||||
pending.onProgress,
|
||||
pending.options,
|
||||
);
|
||||
pending.resolve(move);
|
||||
} catch (error) {
|
||||
|
||||
Reference in New Issue
Block a user