Algorithm Assistant use
The Assistant pages in the app, step by step: toolchain setup, a new algorithm from a description, a change to an existing one, following the writing, and a first simulation of the result.
You want an algorithm written from a description, and you want to see it trade in a simulation. This guide walks through the Assistant pages in the app. For what the Assistant is, what it sends from your computer and what it cannot promise, read Algorithm Assistant first.
Assistant page
Open Assistant in the sidebar. The first time, the page says Starting the Build Agent for a moment: that is the program that writes and builds on your computer.
The toolbar has three parts:
- New algorithm starts a new one.
- Credit shows how much of this period's Assistant credit is used, as a percentage, and the day it resets. The bar turns amber at 80% and red when the credit is used up.
- The toolchain button at the end shows the state of your build tools: Toolchain not checked, Toolchain ready, Toolchain needs attention or Toolchain being set up.
Below the toolbar is the list of your projects. A project is a folder you chose, and the list shows its name, its path and its state:
| State | Meaning |
|---|---|
| Empty | The folder is a project, and no algorithm has been written into it |
| Being written | The Assistant is writing or changing it right now |
| Not built | The code is written, and there is no built library |
| Building | A build is running |
| Built | There is a built library, ready to add to Neurotrader |
| Folder missing | The folder is gone or no longer holds this project |
With no project yet, the page shows Describe an algorithm in your own words and a New algorithm button.
Toolchain setup
Writing an algorithm builds it on your computer, which needs Rust and the C++ build tools. Do this once.
Toolchain check
- Choose the toolchain button at the end of the toolbar. A panel titled Toolchain opens.
- Choose Check now. The check builds an empty algorithm, which can take minutes the first time.
The panel lists C++ build tools, cargo and rustc, each Present or Missing, and the Trial build of an empty algorithm as Passed, Failed or Not tried.
If everything is present and the trial build passed, the button reads Toolchain ready and you can skip the rest of this section.
Setup plan
- In the Toolchain panel, choose Set up. The Toolchain setup dialog opens and looks at what is installed.
- Read what it will install. Each component is listed with what it is for, the size of its download, the space it takes and about how long it takes.
Two things on this screen need your attention:
- Windows asks for permission once. The C++ Build Tools are installed for the whole computer. On an account without administrator rights, Windows asks for an administrator's password at that point.
- Licence terms. The installation shows no licence screen of its own. By choosing Install you accept the terms linked in the dialog.
If the dialog says Neurotrader cannot install a tool on this computer, or you prefer to install the tools yourself, follow the Setup guide link.
Installation
- Choose Install.
- Approve the Windows permission prompt when it appears.
The dialog shows each component as it is downloaded and installed, with a progress bar where the progress is known. The C++ Build Tools take the longest. The last step is a trial build of an empty algorithm.
You can close the dialog. The setup goes on, and choosing Show setup in the Toolchain panel brings it back. Nothing else can be built or written until it has finished.
Stop takes effect between steps. An installer that is already running finishes first.
Setup result
| The dialog says | Meaning | Action |
|---|---|---|
| The toolchain is ready | Everything is installed and a trial build passed | Choose Close and start writing |
| Installed, and a trial build still fails | The tools are there, but an algorithm does not build | Read the build output shown in the dialog. The setup guide covers common causes. |
| Nothing was installed | The Windows permission prompt was not accepted | Start the setup again, or follow the setup guide |
| The setup was stopped | You stopped it. What was installed stays installed. | Start the setup again for the rest |
If Windows asks for a restart to finish the installation, restart before you continue. Programs that were already open, such as a terminal or Visual Studio Code, find the new tools once you restart them.
New algorithm
Description
- Choose New algorithm. The page Describe your algorithm opens on the first of three steps: Describe, Confirm, Write.
- In Project folder, enter or browse to an empty or new folder. The algorithm is written there and named after the folder.
- In Description, say when to buy or sell, and how much. Use plain words, in any language. To start from an example, choose one under Try one.
- Choose Continue.
A good description states a condition, an action and an amount:
Buy when RSI goes under 30 and sell when it is over 70.
Nothing is created yet. The folder becomes a project only when you ask for the algorithm to be written.
If the Assistant cannot build from your text, a note appears under the box with the reason, for example This does not describe a rule yet, and a sentence saying what is missing. Rewrite the description and choose Continue again. Each attempt uses a little of the credit, including one that is refused.
Confirmation
The page Is this what you meant? shows what the Assistant understood.
Read the left side carefully. The code is written from this text, not from your original words.
| Section | Content |
|---|---|
| The readback | One or two sentences stating what the algorithm will do |
| Rules | Each rule as When and Then |
| Amount | How much it trades |
| Instruments | Each instrument in your own words, marked Traded or Read, never traded. You choose the actual instruments when you add the algorithm to a simulation. |
| Tunable parameters | Each parameter with its default |
| Indicators | The indicators it uses |
| Unsupported parts | Anything in your description that cannot be built, and why |
On the right, Open questions lists what your description left open, each with a suggested answer already selected.
- Answer every question. Keep the suggested answer or choose another.
- If you changed an answer, choose Update. The readback is written again with your answers. Read it again. An update uses a little of the credit.
- If something is not what you meant, choose Back and say it differently.
- When the readback is right, choose Write the algorithm.
Writing
The page Writing the algorithm shows the work as it happens, one line per action:
| Line | Meaning |
|---|---|
| Read, Wrote, Edited and a file name | The Assistant read, created or changed that file in your project |
| Build, Tests | A build or a test run, then passed or failed with the time it took |
| Working on the next step | The model is thinking or writing. This can take a minute. |
A failed build or test in the middle is normal. The Assistant reads the output and repairs the code. Writing usually takes about two minutes.
The page lists files and results, not the code. The files are written to your project folder as it goes.
- Leave it running returns to the project list. The work continues and a notification says when it ends.
- Stop ends the writing. The files stay as they were at that moment and may not build.
Result
When it ends well, the page says The algorithm is written and shows:
- Summary: what was written, in the Assistant's words.
- Checks: three marked Passed (you confirmed what it should do, it builds, its own tests pass) and one marked Not yet: that it trades as you intend. A simulation shows that.
From here you can choose Open in editor (Visual Studio Code) or Open folder to read the code, Add to Neurotrader to load it into the engine, or Done to return to the list.
If it ended early, the page says why under Ended:
| Title | Meaning |
|---|---|
| Stopped | You stopped it |
| It did not get there | The algorithm was not finished within the allowed number of steps. Try a simpler description, or describe it in smaller parts. |
| The credit ran out | This period's credit was used up before it finished |
| Not in your plan | Your plan does not include the Assistant |
| The connection was lost | The connection to the Assistant's service dropped and could not be reopened |
| Sign in again | Your session was not accepted |
After an early end the files are as they were at that moment. Choose Open folder to look at them, or start again.
Simulation of the result
A written algorithm has been built and tested. It has not been shown to trade the way you intend. A simulation shows that.
- On the result page, or on the project's card in the list, choose Add to Neurotrader. If the project has no built library yet, it is built first. A first build compiles everything the algorithm depends on and can take several minutes.
- A message says Added to Neurotrader. Choose See it in Algorithms. The algorithm is under Your algorithms with the state Available.
- Create a simulation and add the algorithm to it. See Simulation creation in the app.
- In the Data step, add an instrument for each role the readback named. An algorithm that reads one instrument and trades another needs both.
- Run the simulation and open the run.
If the simulation is refused when you start it, read the message. A written algorithm refuses a set of instruments that does not fill its roles, and says which is missing.
Then check the run against the readback:
- Look at every order on the candle chart. Does each one sit where the rule says it should?
- Does it buy once or repeatedly, as you answered in the open questions?
- Is the amount what you described?
If the orders do not match, the algorithm is wrong, whatever the return says. Change it, as described next, or edit the code yourself.
AI-written code
The Assistant can misread a description and can write code that departs from the readback. Read the code, run it in a simulation and look at every order it places. Do not run it in Real Trade until you have: real money is at risk there. What it trades is your responsibility, and none of this is investment advice.
Change to an existing algorithm
-
On the Assistant page, select the project.
-
Choose Change it. The page What should change? opens, with the project's path above the box.
-
In Change, describe only the change, for example:
Also sell everything if the price closes 8% below the price I bought at.
-
Choose Continue.
-
On Is this what you meant?, read the whole new readback, not only the changed part. Answer any open questions and choose Make the change.
-
Follow the work on Making the change. It ends with The change is made.
-
Choose Add to Neurotrader to load the new build in place of the old one.
The Assistant reads the project's files as they are, including your own edits, so you can mix its changes with yours.
A change is refused while a run is using the algorithm's plugin, at the moment you add it to Neurotrader. Stop the run, or wait for it to finish, and choose Add to Neurotrader again.
Change it is offered once an algorithm has been written into the project.
Project actions
Select a project in the list to use the buttons on its card:
| Button | Effect |
|---|---|
| Change it | Starts a change to the algorithm |
| Open in editor | Opens the folder in Visual Studio Code |
| Open folder | Opens the folder in the file manager |
| Build | Builds the project as it is on disk, including your own edits. If it fails, open the project in your editor to see the compiler's output. |
| Add to Neurotrader | Uploads the built library to the engine, building first if needed |
| Remove from list | Takes the project off this list. No file is deleted. |
To bring back a project you removed or moved, choose New algorithm and enter its folder. A folder that already holds a project is opened, not overwritten.
Messages
| Message | Meaning and remedy |
|---|---|
| The assistant cannot start: The Build Agent is not installed on this computer | The Build Agent is installed with Neurotrader's engine. Install or repair Neurotrader on this computer. |
| The assistant did not answer | The Build Agent could not be reached. Choose Try again. |
| Your plan does not include the assistant | See Plans and quotas |
| This period's assistant credit is used up | Wait for the reset day shown beside the Credit bar |
| The credit could not be checked just now, so nothing was started | Try again shortly. |
| That folder is not empty. Choose an empty one | A new project needs an empty or new folder |
| That folder does not hold a project the assistant made | Change it and Build on this page work on projects the Assistant created |
| This project is being written or built | Wait for the work in progress to end |
| The toolchain is being set up right now | Wait for the setup to finish |
| This readback is no longer valid. Describe the algorithm again | Start from the description again and confirm the new readback |
Visual Studio Code could not be started. Is code on the path? | Install Visual Studio Code, or use Open folder |
| Neurotrader's engine did not answer | Check that the engine is running, then choose Add to Neurotrader again |
| The assistant's service could not be reached | Check your internet connection and try again |
Related
- Algorithm Assistant: what it is and what leaves your computer
- Plugin upload: managing the loaded plugin on the Algorithms page
- Simulation creation in the app
- Run results
- Algorithm confirmation: the check before an algorithm of your own trades real funds
- Plugin authoring: reading and changing the code yourself
Plugin upload
The Algorithms page for your own plugins: upload a built package, link a project on this computer, build, load, unload, reload and remove, with the states and refusals explained.
Notices
How the app tells you about new versions, news and promotions, and how to choose which of them you see.