Learn › Asking your AI

Asking your AI: intermediate

Your own data, and the words for what comes back; still no commands.

Works in chats that run code (with internet), the eLucid8 connector, and coding agents with a terminal.

  1. Messy data

    Paste this into your AI chat:

    Read https://elucid8-lang.org/llms.txt first. Here are eight temperature readings, one an hour: 15, 15.5, missing, 16.5, 17, 17, sensor fault, 18. Use eLucid8 to take their mean, and tell me what it did with the missing reading and the faulty one.

    What comes back: The mean of the six good readings, 16.5, and which readings were left out and why: the third was missing, the seventh a sensor fault.

    What it teaches: A missing reading and a faulty one are told apart and never skipped silently.

  2. Your file

    Download sensors.csv and attach it to your message.

    Paste this into your AI chat:

    Read https://elucid8-lang.org/llms.txt first. I've attached sensors.csv: a reading from each of three sensors every day for two weeks. Use eLucid8 to give me each sensor's average over the last seven days in the file, and tell me if anything was missing.

    What comes back: North 9.37, south 13.15, east 16.17 over 8 to 14 November, and that south’s reading for 10 November is missing (its average is over six days).

    What it teaches: The file’s columns become the program’s dimensions; the AI connects the input to the file.

  3. A range, as a table and a chart

    In the same chat as lesson 1.

    Paste this into your AI chat:

    Now show me, hour by hour, the mean of the good readings so far, as a table and a chart.

    What comes back: Eight rows, 15, 15.25, 15.25, 15.67, 16, 16.2, 16.2, 16.5, and a chart; the mean holds still at the missing hour and at the faulty one.

    What it teaches: Asking for many points at once; results as tables and pictures.

  4. As of a moment

    Paste this into your AI chat:

    Read https://elucid8-lang.org/llms.txt first. Here are two feeds from this morning.
    
    Quotes (time, price): 09:00:00 100.0, 09:00:05 100.4, 09:00:12 100.1, 09:00:30 100.6.
    Trades (time, shares): 09:00:03 50, 09:00:12 20, 09:00:20 10, 09:00:41 30.
    
    Use eLucid8 to price each trade at the quote in force at its time, and tell me how old that quote was.

    What comes back: Prices 100.0, 100.1, 100.1, 100.6, from quotes 3, 0, 8 and 11 seconds old (the 09:00:12 trade takes the quote of the same second).

    What it teaches: Every value carries the time of its newest data; combining streams by time.

  5. A check before running

    In the same chat as lesson 1.

    Paste this into your AI chat:

    Before you run it again, ask eLucid8 to check the program, and tell me in plain words what each value depends on.

    What comes back: The check passes, and what each value reads, in plain words (the mean at an hour reads only the readings up to that hour).

    What it teaches: Checking a program, and reading what it reads.

  6. A repair

    Paste this into your AI chat:

    My AI wrote this eLucid8 program for the running total of my daily sales (3, 1, 4, 0, 5), and it fails with the error below. Read the guide at https://elucid8-lang.org/llms.txt and fix the program from the error message, then show me the running totals.
    
    sales = input("sales", day : 5)
    running = running + sales
    
    elucid8: program.el8:2:1: unguarded cycle: running -> running (a value cannot depend on itself at the same context)

    What comes back: The running totals 3, 4, 8, 8, 13, and the program fixed with fby.

    What it teaches: Giving the AI the guide; error messages name their place, which helps it repair.

Next: Asking your AI: advanced →