« first day (9 days earlier)      last day (712 days later) » 

04:29
ok i got ideas:
- module importing system
- a chain separator which names the chain after, with the string nilad
- importing should be done at the top of the programs
- A quick which calls the named chain
@lyxal how are the ideas
those are a good step towards creating uniqueness from jelly
and in creating simplicity features
but you'll need a bit more than that to fully stand out
people love simplicity
and they love it when languages can do what they want without having to think too hard, even if it isn't golfy
(imo at least)
so that's something to consider
i will implement the module system later
@lyxal any more suggestions?
04:46
I'll have to think on that
because I'm yet to think of how to simplify Jelly
or at least decrease the difficulty for new learners
@lyxal make a good tutorial?
well of course, yes
but that isn't exactly language deisgn related
oh i was also think of making a better error system
something to refer to the very first argument of a train would be good
this might need a bit of explaining
so here's an example Jelly program: 3+µ⁸×
assume it's called monadically
is a nilad that returns the left argument of a link
say I run it with 5 as the input
it outputs 64
because the µ makes it so that the left argument is updated
meaning there's no easy way to access that 5 it was called with
so something that returns 40 instead of 64 would be appreciated
i think i have used alpha and omege for left and args
not sure if they are implemented properly
04:55
but that isn't the original argument
@PyGamer0 they're probably implemented like and in jelly
yeah, but i can use alpha underbar to refer to the original argument of the chain
good
In various places
In on mobile right now so I can't exactly find where they are set
But it's in the chain creation functions
Maybe we could raid the tips for golfing in jelly question for ideas
I've got a potential idea for uniqueness
It's kinda untested and I haven't played around with it fully to see if it would actually be useful
But it could be good
Dyadic quicks.
Quicks that don't just pop from the left but also pop from the right
05:15
ooh nice
As I said, I haven't fully playtested the concept yet
But it could be something like <train><quick><other train>
how would the parser parse it?
Take the remainder of the program after the quick, parse it separately and take the first item
Those kinds of quicks would be mostly for function composition I think
yeah, like APL
Because there's no point having a dyadic quick for mapping for example
05:22
@lyxal but then i dont see the point
5 mins ago, by lyxal
As I said, I haven't fully playtested the concept yet
I'll have to explore the idea a bit more
What could be interesting is some sort of way to create triadic atoms
if theres 3 bytes that implement them then ok
ooh i have an idea for dyadic quick, under (from apl)
@lyxal how?
@PyGamer0 I'm yet to explore the idea
I don't even know if it's possible
But it's something to consider.
Something I'll consider for you
Just off the top of my head, it could involve something like <nilad> <nilad> <triad> <nilad>
There'd have to be a third set of chaining rules
lets make it a 2d language
@lyxal yeah
@PyGamer0 that'd screw up the fact that trains are defined by lines
@PyGamer0 it'd lead to some interesting combos like 3,2,2
05:30
but what are the useful triads
Assign to list, replace x in y with z
That sort of thing
Transliterate, infinite replace
Basically all the triadic elements in Vyxal
ok thats not a bad idea
As I said, I'll experiment with it and see what I come up with
@lyxal and a lone 3 could be left accumulator triad right
for dyadic chains
but do we really need to make triadic chains?
Maybe not
I don't know
05:35
yeah idk about triadic chains
maybe ask in JHT?
probably not
actually maybe
I feel like there'll be people who say the idea is useless because there's some hacky way to do things like that with dyads only
but then there might be people who would appreciate the less hacky way
also another idea could be symbolic math
that could be cool
sympy?
correct
@lyxal can you give some use cases?
mathematical challenges
which have complex formulas
05:42
ok i am posting in JHT about triadic elements
05:54
in Jelly Hypertraining, 31 secs ago, by caird coinheringaahing
Triads don't naturally fit the tacit, one dimensional language design
called it.
I knew it'd be caird to be the first one to say "yesn't"
lol
so what do you think what the others think?
they aren't thinking outside the box
I'm working on a set of example chaining rules
my first draft of monadic chaining rules with triads:
Pattern : curr =
2 3 Ǎ   :  Ǎ(2, 3, curr) -> (2).Ǎ(3, curr)
2 Ǎ 3   :  Ǎ(curr, 2, 3) -> curr.Ǎ(2, 3)
+ × Ǎ 2 :  Ǎ(curr + alpha, curr × alpha, 2) -> (curr + alpha).Ǎ(curr × alpha, 2)
A 1 Ǎ 2 :  Ǎ(A(curr), 1, 2) -> A(curr).Ǎ(1, 2)
Ǎ +     :  Ǎ(curr, alpha, alpha + curr) -> curr.Ǎ(alpha, curr + alpha)
Ǎ I     :  Ǎ(curr, alpha, I(alpha)) -> curr.Ǎ(alpha, I(alpha))
Ǎ 2     :  Ǎ(curr, alpha, 2) -> curr.Ǎ(alpha, 2)
Ǎ       :  Ǎ(curr, alpha, alpha) -> curr.Ǎ(alpha, alpha)
nice
06:09
that's my first draft
i think it would be easy to implement
it's yet to account for dyadic chaining
I think the general idea is to create behaviour for arity patterns that aren't already covered
@lyxal which elements should i implement (monadic and dyadic and niladic)
you mean from vyxal?
from jelly and vyxal
i would say triadic elements for v1.0.0 or something
let me quickly implement running from files
06:32
@lyxal parsing from file fails on:
        arity, is_forward = train_separators.get(subtrain[0][1], (-1, True))
is it because of a trailing newline?
let me check
yes
its because of [] in the split_newlines
i fixed it
i had to filter out [] after splitting on newlines
it works now!
I gotta go for a bit
Maybe half an hour
o/
o/
theres a lot of bugs :/
why
just ... why
07:49
exams are kinda near (8 days away)
>:/
Why is the parser calling the minus sign positive 1?
08:03
@PyGamer0 uninterleave
From the vyxal docs:
y (Uninterleave)
Push every other item of a, and the rest.

Overloads
any a: a[::2], a[1::2] (Every second item, the rest)
It'd return a list of both
@lyxal i dont know
and i am currently doing my project
so the bugs will have to wait to be killed
@PyGamer0 that was more a rhetorical question
I can look into it a bit later
08:41
in Jelly Hypertraining, 5 mins ago, by Unrelated String
yeah there's just no good way to do 1d tacit triads
i've sort of thought of doing some wack stack shit but it's hard to think of a good way to pull that off either
@lyxal ^
 
1 hour later…
10:10
I still personally think it good be a good idea to look into
10:41
ok
time to find out whats causing the bug
@lyxal ^^ lmao
why the hell is it detecting ¯ as 1
ok what the hell, its broken or something ARGH
have you tried ¯+3?
or 3+1?
that should reveal the problem
lmao it does
exactly
why does it do that
that's what I'm working on figuring out
10:57
it does that for all dyads
something is broken
wait is it the variadic_link? or maybe variadic_chain?
3 mins ago, by lyxal
that's what I'm working on figuring out
from flax.interpreter import *; from flax.parser import *; from flax.lexer import *
(tired of typing that)
@lyxal its something to do with the parser
no
no it's not
looks to be an issue with leading_nilad
3+1 should be recognised as a leading nilad
but it isn't
but i copied jelly
@lyxal look
11:17
I think I see what it is
and it's a really obscure bug
I only know what it is because I saw a deepsource alert on vyxal once
if token[0] == TOKEN_TYPE.NUMBER:
                    stack.append(
                        attrdict(
                            arity=0,
                            call=lambda: numberify(token[1]),
                            n=numberify(token[1]),
                        )
                    )
ignore the n=...
that's debugging stuff
call=lambda: numberify(token[1])
that's the culprit
because it's a loop variable in a lambda, it's using the last loop value
from deepsource:
> A variable used in a closure is defined in a loop. This will result in all closures using the same value for the closed-over variable, which can pave way for a hideous bug.
# Motivation: Create 3 functions that return `x**2`, `x**3`, and `x**4`.
# Note: This will be using the loop variable to show the bug.
powers = [lambda x: x**i for i in range(2,5)]
> So, powers is supposed to contain 3 functions to return 2nd, 3rd and 4th powers of a given number. On execution, these are the results:
In [1]: powers = [lambda x: x**i for i in range(2,5)]

In [2]: powers[0](2)  # Expected result: 4 (2**2)
Out[2]: 16

In [3]: powers[1](2)  # Expected result: 8 (2**3)
Out[3]: 16

In [4]: powers[2](2)  # Expected result: 16 (2**4)
Out[4]: 16
why does it happen
@lyxal can you fix it?
just about to push a fix to a new branch ;p
ok
@lyxal does it need to be done for other things as well?
perhaps
we'll see over time
ah this is what jelly does
lambda x=n:x**2
@lyxal i reviewed #8
pls change some things
its now fixed!
thanks
It's lucky I saw that in deepsource that one time
deepsource.io/
11:53
yeah
 
4 hours later…
15:32
and i have an idea for the cli repl
so if no cli args are passed then, start the repl
input a line of code and tokenise, parse and run it, asking for arguments on separate lines of input
then do that again
easy

« first day (9 days earlier)      last day (712 days later) »