ruffsl

joined 3 years ago
MODERATOR OF
 

cross-posted from: https://programming.dev/post/38125775

Nix related discussion starts around the the 0:14:00 min mark.

 

Nix related discussion starts around the the 0:14:00 min mark.

 

Colmena is a simple, stateless NixOS deployment tool modeled after NixOps and morph, written in Rust. It's a thin wrapper over Nix commands like nix-instantiate and nix-copy-closure, and supports parallel deployment.

[โ€“] ruffsl@programming.dev 4 points 11 months ago (1 children)

I've really enjoyed using Kokoro for generating audiobooks:

Be sure to first try using this convenient API wrapper:

Note that not all the modelled voices in Kokoro-82M are of equal quality, given disparities in limited training data from reference speakers. However, what's cool is that you can prescribe polynomial weights to multiple voices tags, enabling you to synthesize different variants weighted more heavily from the highest quality voices.

One current limitation for Kokoro is that there's no way to prescribe emotion or intonation procedurally using markup tags like SSML in the source text, unlike other models like Orpheus. But Orpheus sometimes generate weird hallucinations like repeating sentences, injecting new phrases, appending radio silence or filter words, and generally increasing the tempo of words per minute as a sentence progresses. Still, this may be of interest if you want to add emotion like fear or urgency to your generated dispatches, and manage to tune the input temperature you want for the model.

However, Kokoro is a lot more compute efficient and audibly consistent, requiring less scrutiny or manual supervision. The author behind Kokoro now also looks to be working towards an emotional variant as well:


Reference project I've been following for audiobook generation:

[โ€“] ruffsl@programming.dev 6 points 11 months ago (1 children)

@onlinepersona@programming.dev , this could be really useful for advancing programmatic mutation of pre-existing nix config files using graphical installers and user administ ration tools, like with SnowflakeOS:

[โ€“] ruffsl@programming.dev 3 points 11 months ago (1 children)

Wow, that sounds damning. Where can one read more on this?

[โ€“] ruffsl@programming.dev 1 points 11 months ago (2 children)

This is the flake config I started from, but am now refactoring for multi-host support:

Simple and documented config templates to help you get started with NixOS + home-manager + flakes. All the boilerplate you need!

I first learned of NixOS through this project, but decided on writing my own config for starters.
Still, it has been a neat reference as an advance example:

My main NixOS configuration. Features include a polished Hyprland environment. A fully configured NeoVIM environment, QMK support. A Keyboard shortcut menu pop-down available in the top bar and so much more!


BTW, could you breakdown your hardware.nix configs?
They look a lot different from my auto generated one from the ISO install, particularly for fileSystems:

[โ€“] ruffsl@programming.dev 4 points 11 months ago (1 children)

Ah, that's a shame. Thanks for the context though.

I did feel a little bit of that slight dismissal or elitism from the thread I linked above about the graphical installer ISO. Although I think the relative surge of new users after graphical ISO's implementation did end up changing some minds on the merit of its continual development.

It seems like some tools just never fully realize their potential market demand until they're finally implemented and consequently adopted. Quite the catch 22.

I also wonder if it's a bit of a motivational aspect for individual contributors, as in demand with mostly originate from novice users who've yet to master the Nix language, yet by the time one's gained enough experience to contribute to Snowflake OS, you've kind of grown out of outgrow the need for it. That kind of reflects my personal interests around graphical programming, as I became more familiar with various languages, my inkling for a graphical representation of control flow gradually waned.

Still, I think lowering the barrier to adoption is in the long run best serves the community and in sustaining new contributors. Sort of like the conventional Greek proverb:

A society grows great when old men plant trees whose shade they know they shall never sit in.


Nix can create attribute sets from JSON, so there isn't a need to generate nix code.

Is there a good way of mixing and mashing JSON attribute sets with conventional nix config files? Perhaps relegating some config to machine-generated JSON, and some hand crafted configs?

[โ€“] ruffsl@programming.dev 1 points 11 months ago (1 children)

I'm using flakes as well, so that abomination sounds terrifying...

[โ€“] ruffsl@programming.dev 4 points 11 months ago (1 children)

Indeed, I was unaware of this project. Project commit history looks inactive, but I'm guessing its feature-complete? Looks like someone has rewriten it with an added TUI:

[โ€“] ruffsl@programming.dev 1 points 11 months ago

Oh, I see. Looks like one can use this method to create custom forks of downstream images such as Bazzite:

https://docs.bazzite.gg/Advanced/creating_custom_image/

[โ€“] ruffsl@programming.dev 5 points 11 months ago (3 children)

As a prior proponent of graphical programming interfaces, I've been thinking there'd be a good use case for a GUI based control panel for NixOS, something that could transcompile standard user selected options down to a nix config that could be abstract of the way from most users, like any sort of game save file.

Given all options and packages in nixpkgs are already machine readable and indexed, supplying a GUI based tool to procedurally generate nix codes doesn't at first seem initially daunting, but given the past discussions around this idea perhaps proves it to be on the contrary:

Although SnowflakeOS in particular looks promising:

SnowflakeOS Simple, Immutable, Reproducible SnowflakeOS is a NixOS based Linux distribution focused on beginner friendliness and ease of use.

https://snowflakeos.org/

[โ€“] ruffsl@programming.dev 2 points 11 months ago (3 children)

Yep, with a Turing-complete DSL, there's never just one way to do something in Nix. I find the interaction between modules and overlays particularly quirky, and tricky to replicate from public configs that make advance uses of both.

That said, I do appreciate being able to git blame into public configs, as most will include insightful commit messages or references to ticketed issues that include more discussion with informed community members you can follow up with. Being able to peek at how others fixed something before and after helps give context, and with the commits being timestamped, it also helps gauge current relevancy or chronological order to correlate with upstream changelogs.

Are you using flakes with lock files, or nixpins to fix down the hashes of your nix channel inputs? I like fixating my machines to the same exact inputs so that my desktop can serve as a warm local cache when upgrading my laptop.

[โ€“] ruffsl@programming.dev 2 points 11 months ago (1 children)

Thank you for the detailed reply, much appreciated!

Any rough edges you've encountered yet? Like using USB peripherals, or networking shenanigans? I'm assuming it's using the host network driver by default, and maybe bind mounting /dev/bus/usb for USB pass through?

Think I'll really dig into distrobox today.

view more: โ€น prev next โ€บ