How to create AI Images (Midjourney) by code? - discord

I want to create an app that creates Midjourney images.
The problem is that Midjourney doesn't provide an API, it works from Discord.
How to automate the process of image generation without the need to open Discord?

Related

creating a document with react-docx using uploaded .docx file

So I have a simple, single-page React app. I want to be able to let users drop an MS Word (.docx) file onto a dropzone and then let them download an edited version of their file.
I got the dropzone working and now can access the files in my JS code, and I'm trying to use react-docx to edit the document. It seems that this is a React version of docx.js. However, I only see ways to create brand new documents, not any way to "load in" old ones for editing.
I don't want to start a document from scratch. Is there any way to make a new document using the file that is uploaded?
Anyone is appreciated who has expertise on this or just has a completely better idea for how to achieve my goal.

Is it possible to upload logos for an Alexa Skill using the ASK CLI?

I'm learning how I might manage multiple similar Alexa Skills at scale. I think I have an approach to create and update the skills using gulp-template and the ask-cli.
However, I can't find a way to programmatically upload logos for the skills. Is this possible via the ask cli, or must I upload them manually?
If you are using ask cli, publishing related information will be present in the skill-package/skill.json file. Update the "publishingInformation" section per locale with new logos. Reference:documentation
Use "deploy" command to update the skill.

UWP database of music library storage

I want to know that how can I achieve following functionality in a c#/xaml UWP app.
when the app runs first time it scans all of the music library, folders and files and stuff.
Then it stores in some kind of database at backend.
so whenever u launch app again, it doesnt have to scan again everytime, and it just runs and it already has all the necessary data.
i am guessing that a sqlite database can be used in applicationdata.localfolder
but is there a way that I can save the state and data of all the visual elements of all the pages of my app somewhere in a better way? so that everytime app launches it appears that it was just minimized and then maximized?
thanks in advance.
Save the meta data of songs(name,Path etc)to database table on first launch. On subsequent launch compare the songs count returned from Music API and database table. If it is same fetch from database or else you have to fetch from API It will be much faster on second launch
You have to do first launch operation that is looping through songs collection returned from API and saving to database in async Task so that it won't hang UI
No you can't store storagefile to db.. There is no such compatible type in sqllite. Instead that you can store the path of the song. Actually you have to use path to play the song instead of StorageFile. MediaPlayer play method also takes path to play the song as Uri. Check that.

What is the best way to let users upload pictures to my WPF application

I have a WPF intranet app running in Trusted mode (local only).
I would like the users to be able to upload an image and attach it to an article on my newsletters section. I am having trouble deciding where these images will be stored.
Please provide me with your opinions.
At present I have a few ideas myself;
I could have an aspx page that runs parallel to this app, and run this inside a browser(I-frame). This page could then handle the upload and display of the image.
I could also, have the users copy directly to a network share.
It seems that there should be a more elegant sollution that I am not aware of.
Any ideas?
Don't force the solution towards ASPX just because you know how to do it there. It's unnatural to build a page, host browser to show that page etc, just so you could upload an image.
It's actually quite simpler to do it in a desktop client than on web page. You have a "Load File Dialog" - use that to get to the filepath the user wants to upload, and when you have that you can either:
copy it (inside your application) to your share,
or if you have a service - send it through some method call,
or you can even store it inside a database (recommended if the files are small)
There's really lots of options here... it depends if your client has connection to db, do you have service in between, etc...

How can I access Live Mesh from a Silverlight 3 app?

I have an existing Silverlight 3 app that I want to add Live Mesh support to. This may sound like a simple question but I can't figure out how to get started! I've read a bit on dev.live.com but haven't found a good example. Here's what I want to accomplish:
User visits my SL3 site.
User enters their Live ID and password to login to live (not sure how to do this either).
User sees a list of their files from Live Mesh.
User chooses a file, maybe a text file, and views it in my SL3 app.
Is this possible? I've read about Silverlight enabled Mesh Apps, but it looks like those only run inside the "Live Desktop" part of Mesh. This would be nice as a small addon to my current app but I don't want to push the entire app into the mesh to accomplish this.
This is not possible atm:
http://social.msdn.microsoft.com/Forums/en-US/liveframework/thread/bdeb4de4-3ccd-4510-a227-ae228bf6225f

Resources