🦋 Welcome to the MAIN() IRC channel of the Raku Programming Language (raku.org). Log available at irclogs.raku.org/raku/live.html . If you're a beginner, you can also check out the #raku-beginner channel!
Set by lizmat on 6 September 2022.
festerdam Hi, all! 03:33
tellable6 2024-01-17T12:39:40Z #raku <lizmat> festerdam: do I see a yiddish localization on the horizon ?
festerdam I see the Raku docs repository once provided a means to generate an epub for the whole of the raku documentation, but there is not mention of it in the README anymore. Why is that? 03:35
tellable6: Probably not since I don't know much of it. I can read and understand it somewhat. Add any loshn koydesh and I don't understand anything. :D 03:40
tellable6 festerdam, I haven't seen Probably around
festerdam linkable6: lizmat: Probably not since I don't know much of it. I can read and understand it somewhat. Add any loshn koydesh and I don't understand anything. :D 03:41
(sorry for repeated message)
I just noticed I didn't mention the bot and instead mentioned some random person, I won't resend it, so the chat isn't over and over the same message. 03:44
The makefile for the docs no longer seems to have an "epub" rule, but neither does it seem to have any rules to generate the html pages, so I assume I'm looking in the wrong place. 03:47
Voldenet docs are here github.com/Raku/doc 03:52
festerdam Voldenet: That's the makefile I'm looking at. It only has rules to run tests. 03:54
Voldenet for tooling, readme has mention of rakudoc and doc-website
festerdam Voldenet: Thanks! Seems like doc-website doesn't provide a tool to generate an epub. An issue for it has been opened a year ago. I'll see if there is a way to generate all in a single html page. Maybe I can convert that into an epub. 04:02
Voldenet maybe looking at markdown in raku-pod-render would be a good idea, since it's easier to combine markdown files if necessary 04:04
El_Che 22 10:23
tellable6 2024-01-26T21:34:01Z #raku-dev <jdv> El_Che the 2024.01 release happened
El_Che damn, missed it too busy
will build no
w
antononcube @Voldenet Are you saying that Markdown should be rendered inside Pod? (I think Alexande Zahatski's packages are doing that.) 11:11
Also, I would like to point out that "Markdown::Grammar" can convert Markdown files into Pod6 and HTML. But I do make those kind of conversions often, so there might some (small) glitches and incosistencies. 11:20
El_Che rakudo-pkg released to the repos: ttps://github.com/nxadm/rakudo-pkg/releases/tag/v2024.01 11:25
lizmat El_Che++ 11:34
tbrowder__ hi, asking for advice again. is there any way to define something like a class template. a role is kind of teemplate, but i want to define a methods signature but NOT its insides. something like this: template T { has $.attr1;; 12:10
* has $.attr1; method U(Std 12:11
sorry about the fumble, back later with a gist 12:12
basically i want something like a role that cam 12:13
*can define a method's signature (with its return type) but not its guts 12:14
lizmat role Foo { method bar($a, $b) { ... } }; class A does Foo { } 12:25
m: role Foo { method bar($a, $b) { ... } }; class A does Foo { }
camelia ===SORRY!=== Error while compiling <tmp>
Method 'bar' must be implemented by A because it is required by roles: Foo.
at <tmp>:1
lizmat m: role Foo { method bar($a, $b) { ... } }; class A does Foo { method bar($a) { } }
camelia ( no output )
lizmat m: role Foo { proto method bar($a, $b) {*} }; class A does Foo { method bar($a) { } } 12:26
camelia ( no output )
lizmat m: role Foo { proto method bar($a, $b) {*} }; class A does Foo { multi method bar($a) { } }
camelia ( no output )
lizmat m: role Foo { proto method bar($a, $b) {*} }; class A does Foo { multi method bar($a) { } }; A.foo(42)
camelia No such method 'foo' for invocant of type 'A'
in block <unit> at <tmp> line 1
lizmat m: role Foo { proto method bar($a, $b) {*} }; class A does Foo { multi method bar($a) { } }; A.bar(42)
camelia Too few positionals passed; expected 3 arguments but got 2
in method bar at <tmp> line 1
in block <unit> at <tmp> line 1
lizmat m: role Foo { proto method bar($a, $b) {*} }; class A does Foo { multi method bar($a,$b) { } }; A.bar(42,666)
camelia ( no output )
antononcube @trbrowder The script for generating the "Date::Names" files is here: github.com/antononcube/Date-Names/...ation.raku 12:37
I verified with Bulgarian and Russian language generations. 12:38
tbrowder__ lizmat: thnx, any hope? i think my design needs a rethin 12:47
antononcube: thank you very much! 12:48
lizmat well, with the proto in the role, you *can* force an interface as long as the class also uses multi method
otherwise, you're out of luck I'm afraid
tbrowder__ ok, i'll see. my use case is with very structured data, with your help i mm 12:50
may be able to get it to work. 12:51
antononcube @tbrowder I guess I have to generate the test files too.
tbrowder__ that would be very helpful, thanks so much 12:56
tbrowder__ even without a native language input, we can put the generated data out there and have something a native language user can easely critique rather than expecting a user of the final product to be a raku programmer 12:59
antononcube @tbrowder Right! 13:00
@tbrowder I committed the first versions of the files for Bulgarian, Portuguese, Serbian, and Turkish. I make the test generations later.
See: github.com/antononcube/Date-Names
tbrowder__ i envision an online calendar-type generation site witj language and year selection, button push, and pdf download. 13:01
maybe html with yr llm stuff
antononcube Well, LLMs can be used directly to generate the calendars. But, of course, that is slow. 13:03
tbrowder__ color me skeptical, but i would be surprised to see beautiful pdf output. 13:10
but i guess i could sit here with a microphone and carefully describe the necessary moves...i'm living in a new world! 13:12
tbrowder__ antononcube: any fellow raku ppl in yr part of florida? 13:37
antononcube @tbrowder There might be some, but I do not know them. 🙂 14:18
tbrowder__ i would love to see raku/perl conf back in flow 14:46
florida, the one in 2016 was great, larry, damian, lizmat, bruce gray, and lots more there 14:48
El_Che amterdam 2017 was also with Larry, Damian and Lizmat 14:50
lizmat sadly, Florida, as many other places in the US, are off my list: travelwhiletrans.com/#/us/fl
El_Che crazy shit 14:52
[Coke] the epub generation wasn't working well, and finanalyst has it in his backlog to fix. 15:07
If someone else wants to steal it as a todo, that'd be awesome.
feel free to join us in #raku-doc and chat.
(was never true epub, was just "big html file") 15:08
lizmat: My state of NY is much better if you want to stop by! 15:09
[Coke] is not surprised that his birth state of CT is not as good as NY but not as bad as FL. *sigh*
jdv i think ct has the richest county 15:28
or town...
antononcube Yeah, if I knew about the Raku conference in Orlando 2016, I would have tried to attend. 15:39
I do not live in FL by choice. But it looks I am accustomed to it... 15:41
tbrowder__ with META6.json, is it valid to have a depends line like this: "Foo:api<2>" 15:54
lizmat: so far it looks like yr solution will do the tricks i need, thanks! 16:07
lizmat tbrowder__: Foo:api<2> is valid in despends, and recommended to be as strict as possible 16:08
tbrowder__ cool! 16:09
regarding api 2, so a user just asks zef for Foo, zef should just hand latest version even if there were a later version without an api tag? just asking on off chance in real life one could have (1) Foo:ver<3> and (2) Foo:api<2> without specifying its latest version of 1.9 [hopefully an unlikely case] 16:20
lizmat well, if you want to be sure, you also specify the :auth ad :ver in the depends 16:23
librasteve also worth checking the docs on version class and comparisons since i think you can specify thinks like “v6 or higher” and so on 16:30
tbrowder__ lizmat: thanks 17:20
librasteve: thanks 17:21
antononcube @tbrowder I assume you want to make calendars similar to those found in Emacs calendar function. If yes, then prompting an LLM to do that is most likely not that hard. 19:43
With the following two lines code we get a reasonably good looking calendars (which are correct most of the time.) 19:59
my &fcal0 = llm-function( {"Make make an Emacs style calendar from $^a to $^b.\n" ~ llm-prompt('NothingElse')('Emacs calendar text') }, e => llm-configuration('ChatGPT', model => 'gpt-3.5-turbo', max-tokens => 2048, temperature => 0.12)); &fcal0("January 1, 2024", "April 30, 2024") 20:00
Well, of course, one has to decide where to invest development time: 1) massaging prompts that convince LLMs to produce good looking calendars, 2) make program calendars the "hard way." 20:02
There is also, a third option: 3) figure out which parts LLM does wrong, program that parts in Raku, and then "visualize" using an LLM. 20:03
tbrowder__ antononcube: yes, option 3 sounds like the right path imho 23:50