Search This Blog

Showing posts with label Microsoft. Show all posts
Showing posts with label Microsoft. Show all posts

Monday, July 7, 2025

Introducing My Microsoft Copilot Agent for Oracle ERP & HCM Metadata

Earlier, I shared a blog post detailing a Python-based CLI tool that leveraged Oracle Cloud HCM metadata and generative AI to provide SQL generation, metadata explanation, and table join suggestions. Building on that foundation, I’ve now brought the experience directly into Microsoft 365 using a Copilot Agent integrated with SharePoint.

This new solution allows users to interact naturally with metadata from Oracle ERP and HCM—without ever leaving the Microsoft ecosystem.


What This Copilot Agent Does

This Copilot Agent acts as a metadata consultant within your Microsoft 365 environment. It enables:

  • Natural language discovery of relevant Oracle Cloud tables and columns
  • Contextual SQL generation based on business terms
  • Join recommendations using known key fields like person_id, assignment_id, etc.
  • Explanations of tables, columns, and relationships
  • Starter query generation for BI Publisher reports


Why CSV Metadata Format?

During development, I found that Microsoft Copilot currently does not support JSON-based data sources for grounding

As a result, I converted my metadata files to CSV format to ensure compatibility.

This included structured metadata for tables and columns sourced from both Oracle ERP and HCM Cloud.


Copilot Agent Instructions

Agent Purpose:

You are an intelligent enterprise metadata consultant designed to assist Oracle ERP and HCM users.
You use structured metadata stored in SharePoint to help users explore, understand, and query Oracle Cloud Applications datasets.


Behavioral Instructions (Copilot Agent):

Understand the Metadata:
Use metadata stored in the provided SharePoint folder:

ERP and HCM Tables Metadata

  • Table_Metadata.csv: Contains table-level descriptions and possible usage context.
  • Columns_Metadata.csv Contain schema-level information, including table name, column name, and column descriptions.

First load the Table_Metadata.csv, then load the Columns_Metadata files.
Use the shared table_Id to join columns to their corresponding tables.


Tasks You Can Perform:

  • Suggest which tables or columns are most relevant to a user's query
  • Generate optimized SQL queries based on natural language prompts
  • Recommend joins using shared fields such as person_id, assignment_id, etc.
  • Explain what a specific table or column is used for in business terms
  • Summarize metadata for one or more objects when asked to “explain” or “describe”
  • Help build starter queries for Oracle BI Publisher (BIP) reports
  • Support semantic search (e.g., a search for "payroll balances" should find related metadata even if it’s not an exact match)
  • Act as an expert Oracle Cloud ERP and HCM analyst and developer, capable of solving advanced metadata questions and building queries based on complex requirements


How to Complete the Tasks:

  • Always refer to metadata found in the provided SharePoint files
  • Never fabricate or guess metadata
  • If no matching result is found, say: “I could not find relevant metadata for your request based on the provided files.”
  • If the user provides multiple keywords (e.g., “payroll, salary”), treat them as individual context terms
  • Scan for matches across both table names and descriptions and column descriptions
  • Use exact column name and table name matches where possible
  • Suggest joins using shared fields such as assignment_id, person_id, location_id
  • Prefer documented relationships where available
  • When generating SQL, use clear formatting and include comments if needed
  • When a user says “HCM only” or “Exclude ERP,” make sure results match
  • Clearly state which app (ERP or HCM) an object is part of when helpful
  • When asked to return specific fields (e.g., “name, email, location”), find which columns correspond to those descriptions and which tables they belong to
  • Ensure final responses are concise, technical, and clearly grounded in real metadata


Known Limitations

While this Copilot Agent adds tremendous value, it still has some important limitations:

  • It can hallucinate: If metadata isn’t found due to vague prompts, the agent may fabricate plausible-sounding but incorrect information
  • It requires clear prompting: Users get the best results when they use specific, well-structured queries
  • File linking is not perfect: Even though metadata is grounded in CSV files, deep linking between them can still pose a challenge

Despite these caveats, the Copilot Agent demonstrates how far we can go by bringing structured enterprise metadata and AI together inside the tools we use every day.

Friday, March 28, 2025

How to Create and Manage a Microsoft Teams Copilot Agent

Creating and managing a Teams Copilot Agent can significantly enhance your team's productivity and streamline various tasks. In this blog post, we'll walk you through the steps to set up and configure your agent, along with some useful tips to optimize its performance.

Pre-requisites

Before you start, ensure you have access to Copilot in Teams. You may need to be part of the ACL Group that manages access to the agent. Additionally, users in this group must have access to the SharePoint folder where the source data is located.

Step-by-Step Guide

1. Navigate to Copilot in Teams

In Teams, go to the Copilot section under "Chats."

2. Create an Agent

Click on "Create an Agent" and then select "Configure."



3. Select a Template

You can choose a template that will auto-populate instructions and other fields. These instructions essentially define the persona your agent will assume.

Tip: Pick a template of the kind of agent you want, then place the instructions template in ChatGPT or Copilot or OCI Gen AI and ask it to create a persona based on a given context of your choosing.

4. Point the Agent at Source Data

In the "Knowledge" section, point the agent at the source data. Place the files that will serve as the content for the agent in SharePoint or Teams. You can add up to 20 sources in SharePoint.

Tip: Avoid versioning files; store the latest version of the document. Organize the content and folders the agent is pointing to for higher accuracy.



5. Configure Agent Capabilities

If you want to build an agent that generates images or writes code exclusively, check the respective boxes. For a general-purpose conversational agent, leave these boxes unchecked.

6. Set Starter Prompts

These are prompts users will see when they start a conversation with the agent. You can hardcode common prompts to get users started.



7. Create the Agent

Once all the information is filled out, hit "Create" (top right).

8. Set Access Controls

Enter the ACLs to expose the agent to specific users. Copy the link to the agent and share it with the people who will access it (they also need to have Copilot).

Tip: Individual users may not work depending on your company policies; only ACL groups.

Editing an Agent

To edit an agent, go back to "Create an Agent," click on "View all agents," and navigate to the one you want to edit. You can change the instructions or access settings as needed.

If you are using Microsoft Teams, you can create very useful Agents on top of your existing data and make research, discovery and troubleshooting more engaging, it is a great way to assist new employees or help enhance productivity in general!