Skip to content

Add GET /inference_features route to expose feature registry#258044

Merged
saikatsarkar056 merged 24 commits intoelastic:mainfrom
saikatsarkar056:inference_features_route_api
Mar 18, 2026
Merged

Add GET /inference_features route to expose feature registry#258044
saikatsarkar056 merged 24 commits intoelastic:mainfrom
saikatsarkar056:inference_features_route_api

Conversation

@saikatsarkar056
Copy link
Copy Markdown
Contributor

@saikatsarkar056 saikatsarkar056 commented Mar 17, 2026

Summary

Adds an internal GET /internal/search_inference_endpoints/features route that exposes the Inference Feature Registry. The Model Settings UI needs this route to read all registered features and render the parent-child feature tree.

Manual Testing

I manually tested the this by temporarily registering a test feature in the AI Assistant plugin's start() method and verifying the API response via curl. The route correctly returns registered features.

➜  kibana git:(inference_features_route_api) ✗ curl -su elastic:changeme 'http://localhost:5601/tyn/internal/search_inference_endpoints/features' -H 'x-elastic-internal-origin: kibana' -H 'elastic-api-version: 1' | jq .
{
  "features": [
    {
      "featureId": "ai_assistant",
      "featureName": "AI Assistant",
      "featureDescription": "Conversational AI assistant for security workflows",
      "taskType": "completion",
      "recommendedEndpoints": [
        ".rainbow-sprinkles-completion"
      ]
    }
  ]
}

Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

  • Any text added follows EUI's writing guidelines, uses sentence case text and includes i18n support
  • Documentation was added for features that require explanation or tutorials
  • Unit or functional tests were updated or added to match the most common scenarios
  • If a plugin configuration key changed, check if it needs to be allowlisted in the cloud and added to the docker list
  • This was checked for breaking HTTP API changes, and any breaking changes have been approved by the breaking-change committee. The release_note:breaking label should be applied in these situations.
  • Flaky Test Runner was used on any tests changed
  • The PR description includes the appropriate Release Notes section, and the correct release_note:* label is applied per the guidelines
  • Review the backport guidelines and apply applicable backport:* labels.

Identify risks

Does this PR introduce any risks? For example, consider risks like hard to test bugs, performance regression, potential of data loss.

Describe the risk, its severity, and mitigation for each identified risk. Invite stakeholders and evaluate how to proceed before merging.

@saikatsarkar056 saikatsarkar056 requested a review from a team as a code owner March 17, 2026 01:40
@saikatsarkar056 saikatsarkar056 self-assigned this Mar 17, 2026
@saikatsarkar056 saikatsarkar056 marked this pull request as draft March 17, 2026 01:40
@elasticmachine
Copy link
Copy Markdown
Contributor

🤖 Jobs for this PR can be triggered through checkboxes. 🚧

ℹ️ To trigger the CI, please tick the checkbox below 👇

  • Click to trigger kibana-pull-request for this PR!
  • Click to trigger kibana-deploy-project-from-pr for this PR!
  • Click to trigger kibana-deploy-cloud-from-pr for this PR!
  • Click to trigger kibana-entity-store-performance-from-pr for this PR!
  • Click to trigger kibana-storybooks-from-pr for this PR!

@saikatsarkar056 saikatsarkar056 added 9.4.0 backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes labels Mar 17, 2026
@saikatsarkar056 saikatsarkar056 marked this pull request as ready for review March 17, 2026 22:13
@saikatsarkar056 saikatsarkar056 requested a review from a team as a code owner March 17, 2026 22:13
@kibanamachine
Copy link
Copy Markdown
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#11136

[✅] x-pack/platform/test/serverless/api_integration/configs/search/config.group1.ts: 25/25 tests passed.

see run history

@saikatsarkar056
Copy link
Copy Markdown
Contributor Author

@elasticmachine merge upstream

Copy link
Copy Markdown
Contributor

@steliosmavro steliosmavro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

QA owned file changes look good. Tests are passing the flaky test runner. Just some CI checks that need fix. Overall LGTM! 🚀

@kibanamachine
Copy link
Copy Markdown
Contributor

Flaky Test Runner Stats

🎉 All tests passed! - kibana-flaky-test-suite-runner#11157

[✅] x-pack/platform/test/api_integration/apis/search_inference_endpoints/config.ts: 25/25 tests passed.

see run history

Copy link
Copy Markdown
Member

@sphilipse sphilipse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code looks good to me. I question whether we really need end to end tests to check whether these routes work. That feels like bloating the test suite without adding much testing value. I'd much rather have a few focused browser tests at the end to round it all up rather than a bunch of e2e API tests that test the functionality of an API in isolation.

@saikatsarkar056
Copy link
Copy Markdown
Contributor Author

Code looks good to me. I question whether we really need end to end tests to check whether these routes work. That feels like bloating the test suite without adding much testing value. I'd much rather have a few focused browser tests at the end to round it all up rather than a bunch of e2e API tests that test the functionality of an API in isolation.

Let me remove the integration tests and keep only the unit tests.

Copy link
Copy Markdown
Contributor

@yansavitski yansavitski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@saikatsarkar056 saikatsarkar056 enabled auto-merge (squash) March 18, 2026 19:38
@saikatsarkar056 saikatsarkar056 merged commit 0d1dab7 into elastic:main Mar 18, 2026
21 checks passed
@elasticmachine
Copy link
Copy Markdown
Contributor

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #158 / console app console autocomplete feature Autocomplete shouldnt trigger within a multiline block comment

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
searchInferenceEndpoints 161.3KB 161.4KB +73.0B

History

cc @saikatsarkar056

mbondyra added a commit to mbondyra/kibana that referenced this pull request Mar 19, 2026
…d_agent_navigation2

* commit '9289d6b5502db245e645e190b0246554396c6c20': (34 commits)
  [api-docs] 2026-03-19 Daily api_docs build (elastic#258471)
  [Shared UX][DateRangePicker] Missing parts (elastic#258229)
  [Dashboard] Keep pinned_panels separate in read response (elastic#258444)
  Move inheritance: true to top level in .coderabbit.yml (elastic#258461)
  [DOCS] 9.3.2 Kibana release notes (elastic#257332)
  adds routing accept metric attribute to the cps metric (elastic#258168)
  [ML] AI/Inference Connector creation: use 'location' field to correctly set provider config  (elastic#250838)
  [Lens] Add e2e test for legend list layout (elastic#258160)
  [SigEvents] Convert feature duplication evaluators to createPrompt pattern (elastic#256534)
  Add actionable-obs author to .coderabbit.yml (elastic#257922)
  [DOCS] 9.2.7 Kibana release notes (elastic#257331)
  Grant Serverless editor/viewer access to ES v2 indices (elastic#258384)
  [SigEvents][Evals] Rename terminology for KI features and KI queries (elastic#258361)
  [EDR Workflows][Osquery] Add shared table toolbar components and redesign saved queries list (elastic#258394)
  [Automatic Import V2] Upload samples using an existing index (elastic#258074)
  Add GET /inference_features route to expose feature registry (elastic#258044)
  fix additional fields not included (elastic#257625)
  [Discover] [Metrics] Add tier 2 journeys for Metrics in Discover E2E (elastic#255036)
  [Lens as code] Support correct X-Axis types in ES|QL visualizations (elastic#258159)
  Update APM (main) (elastic#254880)
  ...
flash1293 pushed a commit to flash1293/kibana that referenced this pull request Mar 19, 2026
…#258044)

## Summary

Adds an internal `GET /internal/search_inference_endpoints/features`
route that exposes the Inference Feature Registry. The Model Settings UI
needs this route to read all registered features and render the
parent-child feature tree.

#### Manual Testing
I manually tested the this by temporarily registering a test feature in
the AI Assistant plugin's start() method and verifying the API response
via curl. The route correctly returns registered features.

```
➜  kibana git:(inference_features_route_api) ✗ curl -su elastic:changeme 'http://localhost:5601/tyn/internal/search_inference_endpoints/features' -H 'x-elastic-internal-origin: kibana' -H 'elastic-api-version: 1' | jq .
{
  "features": [
    {
      "featureId": "ai_assistant",
      "featureName": "AI Assistant",
      "featureDescription": "Conversational AI assistant for security workflows",
      "taskType": "completion",
      "recommendedEndpoints": [
        ".rainbow-sprinkles-completion"
      ]
    }
  ]
}
```


### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [ ] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
- [ ] If a plugin configuration key changed, check if it needs to be
allowlisted in the cloud and added to the [docker
list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)
- [ ] This was checked for breaking HTTP API changes, and any breaking
changes have been approved by the breaking-change committee. The
`release_note:breaking` label should be applied in these situations.
- [x] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [x] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
- [x] Review the [backport
guidelines](https://docs.google.com/document/d/1VyN5k91e5OVumlc0Gb9RPa3h1ewuPE705nRtioPiTvY/edit?usp=sharing)
and apply applicable `backport:*` labels.

### Identify risks

Does this PR introduce any risks? For example, consider risks like hard
to test bugs, performance regression, potential of data loss.

Describe the risk, its severity, and mitigation for each identified
risk. Invite stakeholders and evaluate how to proceed before merging.

- [ ] [See some risk
examples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)
- [ ] ...

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
jeramysoucy pushed a commit to jeramysoucy/kibana that referenced this pull request Mar 26, 2026
…#258044)

## Summary

Adds an internal `GET /internal/search_inference_endpoints/features`
route that exposes the Inference Feature Registry. The Model Settings UI
needs this route to read all registered features and render the
parent-child feature tree.

#### Manual Testing
I manually tested the this by temporarily registering a test feature in
the AI Assistant plugin's start() method and verifying the API response
via curl. The route correctly returns registered features.

```
➜  kibana git:(inference_features_route_api) ✗ curl -su elastic:changeme 'http://localhost:5601/tyn/internal/search_inference_endpoints/features' -H 'x-elastic-internal-origin: kibana' -H 'elastic-api-version: 1' | jq .
{
  "features": [
    {
      "featureId": "ai_assistant",
      "featureName": "AI Assistant",
      "featureDescription": "Conversational AI assistant for security workflows",
      "taskType": "completion",
      "recommendedEndpoints": [
        ".rainbow-sprinkles-completion"
      ]
    }
  ]
}
```


### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [ ] Any text added follows [EUI's writing
guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses
sentence case text and includes [i18n
support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)
- [ ]
[Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html)
was added for features that require explanation or tutorials
- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
- [ ] If a plugin configuration key changed, check if it needs to be
allowlisted in the cloud and added to the [docker
list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker)
- [ ] This was checked for breaking HTTP API changes, and any breaking
changes have been approved by the breaking-change committee. The
`release_note:breaking` label should be applied in these situations.
- [x] [Flaky Test
Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was
used on any tests changed
- [x] The PR description includes the appropriate Release Notes section,
and the correct `release_note:*` label is applied per the
[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)
- [x] Review the [backport
guidelines](https://docs.google.com/document/d/1VyN5k91e5OVumlc0Gb9RPa3h1ewuPE705nRtioPiTvY/edit?usp=sharing)
and apply applicable `backport:*` labels.

### Identify risks

Does this PR introduce any risks? For example, consider risks like hard
to test bugs, performance regression, potential of data loss.

Describe the risk, its severity, and mitigation for each identified
risk. Invite stakeholders and evaluate how to proceed before merging.

- [ ] [See some risk
examples](https://github.com/elastic/kibana/blob/main/RISK_MATRIX.mdx)
- [ ] ...

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting release_note:skip Skip the PR/issue when compiling release notes v9.4.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants