Skip to content

Commit

Permalink
Move todos from README to GitHub
Browse files Browse the repository at this point in the history
Also adds ari --help output to README
  • Loading branch information
semperos committed Nov 1, 2024
1 parent 16c00c4 commit 1a181c1
Showing 1 changed file with 25 additions and 28 deletions.
53 changes: 25 additions & 28 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,31 @@ go install github.com/semperos/ari/cmd/ari@latest

Then run `ari` for a REPL or `ari --help` to see CLI options.

```
ari is an interactive environment for array + relational programming.
It embeds the Goal array programming language, with extensions for
working with SQL and HTTP APIs.
Usage:
ari [flags] [source file]
Flags:
--config string ari configuration (default "$HOME/.config/ari/ari-config.yaml")
--cpu-profile write CPU profile to file
-d, --database string DuckDB database (default: in-memory)
--debug enable detailed debugging output on panic
-e, --execute string string of Goal code to execute, last result not printed automatically
-h, --help help for ari
--history string history of REPL entries (default "$HOME/.config/ari/ari-history.txt")
-l, --load stringArray Goal source files to load on startup
-m, --mode string language mode at startup (default "goal")
-f, --output-format string evaluation output format (default "goal")
-p, --println print final value of the script + newline
-r, --raw raw REPL w/out history or auto-complete
-v, --version print version info and exit
```

## Features

- [Goal] is the core language
Expand Down Expand Up @@ -42,34 +67,6 @@ Then run `ari` for a REPL or `ari --help` to see CLI options.
- Help entries for SQL keywords (shown during auto-complete, still WIP)
- Results of the last-run query/command set to the `sql.p` Goal global (for "SQL previous" and mirroring `ari.p`), so you can switch between `)sql` and `)goal` at the REPL to run queries via SQL and do data processing via Goal.

## To Do

See [CHANGES.md](CHANGES.md) for recent changes.

Non-exhaustive list:

- IN PROGRESS: Test coverage
- IN PROGRESS: Consider which of ari's functions should be pervasive; review Goal's approach and implement
- TODO: Consider which of ari's pervasive functions should operate on dictionaries
- TODO: BUG When using `-l` flag, loaded files aren't completely evaluated. Evaluation stops partway through and it's not immediately clear why.
- TODO: BUG `json.tbl` produces improper zero values when keys are missing. Where possible, column lists should be of uniform type and not generic if the data allows for it.
- TODO: Make version of `fmt.tbl` that allows setting maximum column width.
- TODO: Functions to conveniently populate SQL tables with Goal values.
- TODO: User commands (as found in [APL](https://aplwiki.com/wiki/User_command)), executable from Goal or SQL modes
- TODO: Integrate rate limiting/shaping (perhaps via uber-go/ratelimit)

I plan to support the above items. The following are stretch goals, nice-to-have's, or thoughts for further consideration:

- TODO: Use custom table functions via replacement scan to query Goal tables from DuckDB.
- TODO: `)help` for cross-mode help
- TODO: System functions to switch between rich and raw REPL `)repl.rich` and `)repl.raw`
- IN PROGRESS: `tui.` functions in CLI mode using https://github.com/charmbracelet/lipgloss (already a transitive dependency) for colored output, etc.
- TODO: Implement a subset of [q](https://code.kx.com/q/) functions to extend what Goal already has.
- Specific user commands:
- TODO: Toggle pretty-printing (TBD what this means; can use JSON output at this point for possibly more familiar output)
- TODO: Toggle paging at the REPL (as found in [PicoLisp](https://picolisp.com/wiki/?home))
- TODO: Toggle colored output

## Examples

I began building Ari to replicate the experience described in the [Background](#background) section of this README. That code is not publicly available at this time.
Expand Down

0 comments on commit 1a181c1

Please sign in to comment.