Skip to content

Comments

fix: Improve usage reporting#228

Draft
jsonbailey wants to merge 3 commits intomainfrom
devin/AIC-1636-1771885282-improve-usage-reporting
Draft

fix: Improve usage reporting#228
jsonbailey wants to merge 3 commits intomainfrom
devin/AIC-1636-1771885282-improve-usage-reporting

Conversation

@jsonbailey
Copy link
Contributor

@jsonbailey jsonbailey commented Feb 23, 2026

Requirements

  • I have added test coverage for new or changed functionality
  • I have followed the repository's pull request submission guidelines
  • I have validated my changes against all supported platform versions

Related issues

Describe the solution you've provided

Updates the .NET AI SDK's usage tracking to align with the updated spec. Key changes:

  1. Renamed usage tracking event key from $ld:ai:config:function:single to $ld:ai:usage:completion-config, following the new $ld:ai:usage:* naming convention from the spec.

  2. Added SDK info tracking on initialization ($ld:ai:sdk:info). When LdAiClient is constructed, it fires a tracking event with aiSdkName, aiSdkVersion, and aiSdkLanguage using an anonymous context (kind ld_ai, key ld-internal-tracking). SDK metadata lives in a new SdkInfo static class (SdkInfo.cs) for reuse across the package.

  3. Renamed Config method to CompletionConfig on both ILdAiClient and LdAiClient. The old Config method is preserved but marked [Obsolete] and proxies to CompletionConfig.

Note: The .NET SDK does not currently have agent, judge, createChat, or createJudge methods, so only the single completion-config usage event key needed updating.

Human review checklist

  • Verify event key strings ($ld:ai:sdk:info, $ld:ai:usage:completion-config) exactly match the spec
  • Verify the anonymous context (kind ld_ai, key ld-internal-tracking) matches spec requirement 1.2.2.1
  • Confirm SdkInfo.Version = "0.9.1" with // x-release-please-version comment is compatible with this repo's release-please configuration
  • Confirm the breaking ILdAiClient interface change (adding CompletionConfig) is acceptable for a pre-release SDK
  • Verify that SDK info tracking firing per LdAiClient instantiation (rather than once globally) aligns with spec intent

Additional context

Co-Authored-By: unknown <>
@devin-ai-integration
Copy link
Contributor

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

@devin-ai-integration devin-ai-integration bot added the devin-pr PR was created by Devin AI label Feb 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

devin-pr PR was created by Devin AI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant