Skip to content

Instrumentation#270

Draft
gewenyu99 wants to merge 3 commits into
mainfrom
loop
Draft

Instrumentation#270
gewenyu99 wants to merge 3 commits into
mainfrom
loop

Conversation

@gewenyu99

Copy link
Copy Markdown
Collaborator

Created a tracker that is called through:

tracker?.onMessage(message);

and runs parallel to the agent to benchmark things like:

  • Input and output size
  • Context size
  • Log compactions
  • Turns per phase (that's what I'm calling each of the prompts we have in llm-prompts
  • Time per turn
  • Cost

What's cool is that we can use a similar pattern to build all kinds of plugins and instrumentation, so I might generalize this in the future to an interface...

sarahxsanders added a commit that referenced this pull request Jul 22, 2026
Adds Java (server) as a supported framework, stacked on the Rust framework PR:

- Integration.java enum entry ordered after kmp/swift/android — those claim gradle projects first — and before the language fallbacks
- JAVA_AGENT_CONFIG in src/frameworks/java/ — claims pom.xml unconditionally (Maven is unambiguously JVM backend) and root gradle files only when they carry no Android/KMP plugin markers and no AndroidManifest.xml subtree exists; gathers buildTool (maven | gradle) as agent context; installs by editing the build file with com.posthog:posthog-server then resolving with mvn install / gradle build
- detectJavaPackageManagers detector (Maven via pom.xml, Gradle fallback reusing gradlePackageManager) + FRAMEWORK_REGISTRY entry
- No bash-fence changes needed: mvn/mvnw and gradle/gradlew grammars already exist from Android/KMP
- Pins framework: java on a new integration-java entry in the variant-resolution contract test, matching context-mill PR #270 which must release before this merges
- Marks pom.xml as a real framework target in the agentic manifest comment, leaving .NET as the only manifest without a target

Generated-By: PostHog Code
Task-Id: 9c949855-7611-48f2-b8b5-7aa4112543e5
sarahxsanders added a commit that referenced this pull request Jul 22, 2026
Adds Java (server) as a supported framework, stacked on the Rust framework PR:

- Integration.java enum entry ordered after kmp/swift/android — those claim gradle projects first — and before the language fallbacks
- JAVA_AGENT_CONFIG in src/frameworks/java/ — claims pom.xml unconditionally (Maven is unambiguously JVM backend) and root gradle files only when they carry no Android/KMP plugin markers and no AndroidManifest.xml subtree exists; gathers buildTool (maven | gradle) as agent context; installs by editing the build file with com.posthog:posthog-server then resolving with mvn install / gradle build
- detectJavaPackageManagers detector (Maven via pom.xml, Gradle fallback reusing gradlePackageManager) + FRAMEWORK_REGISTRY entry
- No bash-fence changes needed: mvn/mvnw and gradle/gradlew grammars already exist from Android/KMP
- Pins framework: java on a new integration-java entry in the variant-resolution contract test, matching context-mill PR #270 which must release before this merges
- Marks pom.xml as a real framework target in the agentic manifest comment, leaving .NET as the only manifest without a target

Generated-By: PostHog Code
Task-Id: 9c949855-7611-48f2-b8b5-7aa4112543e5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant