- Version: 1.0
- Last update: Apr 2026
- Environment: Python + Git + Copilot
Setting up a new Python data project — creating virtual environments, installing packages, configuring library credentials, and scaffolding notebooks — is a repetitive process that every developer has to go through, often from scratch each time. This project shows how that entire workflow can be driven by a single AI prompt, with no manual steps required.
This project demonstrates how to use a copilot-instructions.md file to automatically set up a complete LSEG Data Library for Python Jupyter Notebook environment using GitHub Copilot. The setup is triggered through either the GitHub Copilot Chat extension for VS Code or the Copilot CLI — whichever fits your preferred workflow.
The .github/copilot-instructions.md file at the heart of this project acts as a structured, step-by-step runbook that Copilot reads and executes. It instructs Copilot to create a Python virtual environment, upgrade pip, install the required packages (lseg-data and jupyterlab), generate a requirements.txt, create and populate a Jupyter notebook with working LSEG Data Library code, write the library configuration file, and finally commit everything to a new Git branch — all from a single prompt.
The goal is to demonstrate that GitHub Copilot's agentic capabilities extend well beyond code completion. With the right instructions, Copilot can reliably automate the full environment lifecycle, making it straightforward for any team member — regardless of their familiarity with the LSEG Data Library — to get a working development environment up and running in minutes.
This project and the .github/copilot-instructions.md file were tested on Windows with the following Copilot models
- Claude Sonnet 4.6: Both Chat Extensions and Copilot CLI
- Claude Opus 4.6: Both Chat Extensions and Copilot CLI
- GPT-5.4: Both Chat Extensions and Copilot CLI
If you use a different model, ask it to review and revise .github/copilot-instructions.md file with your review, then retest the instructions until it satisfies your requirements.
GitHub Copilot is an AI coding assistant that helps you write code faster and with less effort. Then, you can focus more energy on problem solving and collaboration. It supports multiple AI models. The GitHub Copilot integrates with your favorite IDE such as VS Code, MS Visual Studio, JetBrains IDEs family, Apple XCode, Eclipse, etc. for the seamless workflow.
I am demonstrating with the VS Code and the GitHub Copilot Chat extension for VS Code extension.
Copilot CLI is a command line interface tool allows you to use the Copilot directly from your terminal. You can use it to answer questions, write and debug code, and interact with GitHub.com. For example, you can ask Copilot to make some changes to a project and create a pull request.
GitHub Copilot CLI gives you quick access to a powerful AI agent, without having to leave your terminal. It can help you complete tasks more quickly by working on your behalf, and you can work iteratively with GitHub Copilot CLI to build the code you need.
Before you begin, ensure the following are installed and available on your PATH:
- Python 3.11 or higher — python.org/downloads
- Git — git-scm.com
- Copilot CLI or GitHub Copilot Chat extension for VS Code — with access to this repository
- Network access to PyPI (or a trusted mirror)
- If you are using the Desktop Session: The LSEG Workspace Desktop application is required.
- If you are using the Platform Session: The LSEG Data Platform account and permission is required.
- If you are using the Streaming services within a deployed ADS: The local deployed ADS server Hostname/IP Address, WebSocket Port, DACS username (if any) is required. Please contact your Market Data Team.
You can find more regarding each connection type setting in the Data Library Quickstart page.
DataLib_Copilot/
├── .github/
│ └── copilot-instructions.md # Copilot setup guide (for VS Code Copilot Chat and Copilot CLI)
├── .vscode/
│ └── settings.json # VS Code setting
├── .venv/ # Python virtual environment (git-ignored)
├── notebook/
│ ├── ld_notebook.ipynb # Example Data Library for Python JupyterLab notebook
│ └── lseg-data.config.json # LSEG Data Library configuration file
├── .gitignore
├── LICENSE.md # Apache 2.0
├── Project_README.md # Example Project's README file
├── README.md # README for "this Repository"
├── images/ # "this Repository" images folder
└── requirements.txt
This project includes a .github/copilot-instructions.md file for both GitHub Copilot Chat extension for VS Code and Copilot CLI that tells Copilot how to set up the entire project automatically.
The given .github/copilot-instructions.md file set up the project for the Desktop Session by default.
-
Open the project folder in a terminal or VS Code:
cd path\to\DataLib_Copilot
-
If you are using the Platform Session or Deployed ADS connection type, update the
lseg-data.config.jsontemplate content in the Part 1 section of.github/copilot-instructions.mdfile to match your connection type (see the What If I Am Using the Platform Session Or Deployed ADS? section below). Please do not input your credential to the.github/copilot-instructions.mdfile. -
Start GitHub Copilot CLI in the project directory (using Powershell is recommended) or Open GitHub Copilot Chat session.
GitHub Copilot Chat example.
Copilot CLI example.
-
Select a Copilot model that suits your need.
GitHub Copilot Chat example
Copilot CLI examples
-
Run the setup prompt:
run all tasks in my copilot-instructions.md fileGitHub Copilot Chat examples
-
Review each Copilot request step with caution. Different models and run times may prompt you for request messages differently — click Approve/Allow only when you are satisfied the action is appropriate to proceed.
GitHub Copilot Chat example
Copilot CLI example
Copilot then performs the following tasks based on the
.github\copilot-instructions.mdmarkdown file:- Create a
.venvPython virtual environment - Upgrade
pipand installlseg-data+jupyterlab - Generate
requirements.txt - Create
notebook/ld_notebook.ipynbandnotebook/lseg-data.config.json - Add
README.md, and.gitignorefiles - Create a new Git branch named
setup-project, then stage and commit all files to it
- Create a
-
Once the process is completed, you see the following kind of message from Copilot that it has finished all tasks.
GitHub Copilot Chat example
Copilot CLI example
-
Please note that sometimes Copilot may skip steps or become idle while running tasks; if this happens, send another prompt to make it continues tasks.
GitHub Copilot Chat example
Copilot CLI example
-
You see the following project structure when the process is finished.
After the automated setup finishes, review these project-specific items before you publish or reuse the repository:
-
Start and login the Workspace Desktop application, or configure the
notebook\lseg-data.config.jsonwith your Data Platform/Deployed RTDS credential and information. -
Run the notebook
ld_notebook.ipynbto verify your connection and permission. -
Add the correct copyright owner and year to
LICENSE.mdif you want to include a project-specific notice. -
Update this
README.mdso the title, overview, setup notes, and session guidance match your actual project. -
Update the
imagesfolder to match your project/repository images. -
Mange the Git repository based on your preference (create new branch, etc.).
-
Start coding!!
If you are using the Platform Session, you can configure a notebook/lseg-data.config.json file template based on the type of your connection type and update the notebook/lseg-data.config.json content in .github\copilot-instructions.md markdown file.
Machine-ID (GE-A-XXXXXXXX-X-XXXX)
{
"logs": {
"level": "info",
"transports": {
"console": {
"enabled": false
},
"file": {
"enabled": false,
"name": "lseg-data-lib.log"
}
}
},
"sessions": {
"default": "platform.ldp",
"platform": {
"ldp": {
"app-key": "YOUR APP KEY GOES HERE!",
"username": "YOUR LDP LOGIN OR MACHINE GOES HERE!",
"password": "YOUR LDP PASSWORD GOES HERE!",
"signon_control": true
}
}
}
}Service Account (GE-XXXXXXXXXXXX)
{
"logs": {
"level": "info",
"transports": {
"console": {
"enabled": false
},
"file": {
"enabled": false,
"name": "lseg-data-lib.log"
}
}
},
"sessions": {
"default": "platform.ldpv2",
"platform": {
"ldpv2": {
"client_id": "Service-ID (Client ID V2)",
"client_secret": "Client Secret",
"signon_control": true,
"app-key": ""
}
}
}
}
Deployed ADS
{
"logs": {
"level": "info",
"transports": {
"console": {
"enabled": false
},
"file": {
"enabled": false,
"name": "lseg-data-lib.log"
}
}
},
"sessions": {
"default": "platform.deployed",
"platform": {
"deployed": {
"app-key": "YOUR APP KEY GOES HERE!",
"realtime-distribution-system": {
"url": "YOUR DEPLOYED HOST:PORT GOES HERE!",
"dacs": {
"username": "YOUR DACS ID GOES HERE!",
"application-id": 256,
"position": ""
}
}
}
}
}
}
You can find more regarding each connection type setting in the Data Library Quickstart page.
The project is licensed under the Apache License 2.0.
This project demonstrates how a well-crafted copilot-instructions.md file can turn GitHub Copilot into a reliable project setup assistant — capable of automating repetitive environment configuration step-by-step tasks from a single natural language prompt.
-
Repeatable setup: The
.github/copilot-instructions.mdfile acts as a machine-readable runbook. Any developers with access to the repository and GitHub Copilot can reproduce the full environment — virtual environment, dependencies, notebook, and configuration files — without reading lengthy documentation or running commands manually. -
Model flexibility: The same instruction file works across multiple Copilot models (Claude Sonnet 4.6, GPT-5.4, and Auto model selection), both in the VS Code Copilot Chat extension and Copilot CLI. This means the workflow is not locked to a single AI provider.
-
Reduced onboarding friction: New team members can get a working LSEG Data Library Jupyter Notebook environment running in minutes, regardless of their familiarity with the library or its configuration requirements.
-
Customizable for different connection types: The instruction file is straightforward to adapt — updating the
lseg-data.config.jsonblock is all that is needed to switch between Desktop Session, Platform Session, and Deployed ADS workflows. -
Version-controlled intent: Storing setup instructions alongside the code in
.github/copilot-instructions.mdkeeps the "how to set up this project" knowledge inside the repository itself, where it is versioned, reviewable, and improvable like any other source file.
This pattern is most valuable when:
- A project requires a non-trivial environment setup (specific packages, configuration files, directory structure).
- The setup needs to be reproducible across different machines or team members.
- You want to reduce reliance on external wikis or onboarding documents that can drift out of sync with the codebase.
By combining GitHub Copilot's agentic capabilities with a structured instruction file, this project shows that AI-assisted automation does not have to be limited to writing application code — it can manage the entire developer environment lifecycle.
You can find more detail regarding the Data Library and GitHub Copilot from the following resources:
- LSEG Data Library for Python on the LSEG Developer Community website.
- Data Library for Python - Reference Guide
- The Data Library for Python - Quick Reference Guide (Access layer) article.
- Essential Guide to the Data Libraries - Generations of Python library (EDAPI, RDP, RD, LD) article.
- Upgrade from using Eikon Data API to the Data library article.
- Data Library for Python Examples on GitHub repository.
- GitHub Copilot documentation.
- Adding custom instructions for GitHub Copilot CLI.
- Adding repository custom instructions for GitHub Copilot.
For any question related to this example or Data Library, please use the Developers Community Q&A Forum.














