Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BC Idea]: [Number Series Copilot] Implement Semantic Text Comparison for Enhanced Number Series Matching #2107

Open
1 task done
DmitryKatson opened this issue Sep 26, 2024 · 2 comments
Assignees
Labels
Approved The issue is approved BCIdea Issue related to a BCIdea Integration GitHub request for Integration area Linked Issue is linked to a Azure Boards work item

Comments

@DmitryKatson
Copy link
Contributor

DmitryKatson commented Sep 26, 2024

BC Idea Link

https://experience.dynamics.com/ideas/idea/?ideaid=ae4b0c3a-30d6-ee11-92bd-000d3adb9365

Description

New Feature: Semantic Comparison for Number Series Copilot

Feature Request: Implement Semantic Text Comparison for Enhanced Intent Understanding

  • Current Behavior: The Number Series Copilot relies on a keyword-based comparison to match user requests with the corresponding entities in Business Central. For example, when a user asks for an employee Number Series, the system works as expected because it can find a match with the "Employee Nos." keyword in the "Human & Resources Setup" table.

  • Problem: If a user uses a synonym or a different phrase, such as "payroll worker," the current keyword comparison does not find the corresponding entity (e.g., "employee"), leading to failure in generating the Number Series.

  • Proposed Solution:

    • Implement a semantic comparison mechanism using a cosine similarity algorithm to compare user requests with existing entities, even if synonyms or different phrases are used.
    • Semantics Vocabulary Table: Build a vocabulary of requested entities (e.g., "employee", "payroll worker") and existing setup tables and no. series fields (e.g., "human resources employee") with text values mapped to vectors.
    • Vectors: Generate and store vectors in the blob field of this semantic vocabulary when the user installs the app or upon the first query.
    image
    • Azure OpenAI Embeddings: If a match is not found in the predefined vocabulary, use Azure OpenAI Embeddings to generate vectors for the new phrase or term.
    • Embedding Deployment: To integrate this feature, add text-embedding-ada-002 embedding model to the AOAIDeployments.GetEmbeddingAda002(). Ensure that the Azure OpenAI Embeddings are accessible for use when a semantic comparison is required.

Steps to Implement:

  • Build a semantic vocabulary of text values with corresponding vectors for entity name comparison.
  • Store the vectors in Blob field during installation or first use.
  • Integrate Azure OpenAI Embeddings for cases where the vocabulary does not provide a match.
  • Ensure the Number Series Copilot can dynamically switch between keyword comparison and semantic comparison as needed.

Acceptance Criteria:

  • Semantic comparison allows the Copilot to correctly interpret synonymous terms (e.g., "payroll worker" as "employee") and generate the correct Number Series.
  • Integration with Azure OpenAI Embeddings for real-time semantic comparison when no match is found in the stored vocabulary.

I will provide the implementation for this BC Idea

  • I will provide the implementation for this BC Idea
    Internal work item: AB#503148
@DmitryKatson DmitryKatson added the BCIdea Issue related to a BCIdea label Sep 26, 2024
@bcbuild-github-agent bcbuild-github-agent added the Linked Issue is linked to a Azure Boards work item label Sep 27, 2024
@JesperSchulz
Copy link
Contributor

I will consult our platform team to hear about their plans to make semantic search available for AL developers. Stay tuned.

@JesperSchulz
Copy link
Contributor

Platform will collaborate with you on providing support. We will park this issue for now!

@JesperSchulz JesperSchulz added the Integration GitHub request for Integration area label Sep 30, 2024
@JesperSchulz JesperSchulz self-assigned this Nov 14, 2024
@JesperSchulz JesperSchulz added the Approved The issue is approved label Dec 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Approved The issue is approved BCIdea Issue related to a BCIdea Integration GitHub request for Integration area Linked Issue is linked to a Azure Boards work item
Projects
None yet
Development

No branches or pull requests

3 participants