How to create a public google colab notebook for each individual? - google-colaboratory

I would like to create a public Google Colab notebook that people can use to perform a specific calculation, but I am not sure how to create a notebook that is unique to each visitor. In that, I mean that when each person clicks a link, they should be able to use and manipulate the notebook but that should not affect what other users see and do.
An example is the Colab notebook for AlphaFold: https://colab.research.google.com/github/sokrypton/ColabFold/blob/main/AlphaFold2.ipynb. Each person can access this notebook but if one person is working on it, no one else can see what that person is doing.
Hopefully this question makes sense.

This is possible by default.
As long as your visitors don't have editing permissions their interaction with the notebook won't be visible to other visitors (and editors).
They will see, however, any interactions (namely cell outputs) made by the notebook's editor(s).

Related

How do I extract user details for Bloomberg Desktop API connection?

If you type IAM <GO> in the terminal you'll be shown the UserID, UUID, CLID etc.
Is it possible to extract this information through blpapi when using the Desktop API to connect via BBComm? I've seen references to Identity and populating that by sending an AuthorizationRequest but it appears that's only relevant for SAPI/B-PIPE.
To the best of my knowledge and after asking a couple of Bloomberg reps - this isn't possible. The best work around which I've found is: each user creates an EQS screen called their UUID. Add some filtering which causes this screening to return nothing. Then the application, upon start up, requests all possible UUIDs as EQS screens and stops when it doesn't get back an error - that's the UUID.
This is a dirty, dirty hack and, granted, this only works if you have few distinct users using your system. You don't want to ask may users to create such a screen and probably don't want to iterate over thousands of EQS screen names.
There is a "SID report" which is provide together with monthly invoices from Bloomberg which contains the UUIDs for users - this can be used to look up existing users but when setting up a brand new account you have to manually copy this information out of the terminal.

How can I save or get data about places near me without breaking policies

This is more of a general programming question.
I'm trying to create an app, think of it as a Yelp clone. I have most of it working but I'm missing one important feature. The data of the places around me. For now I'm only focused on food, so I'd like it if I search something like "Pizza", it'd show me all the pizza joints near me.
I was originally planning to use Google Places API. However if you havent heard, they're changing their pricing and lowering the free tier and upping the cost by a huge margin.
There's also the problem of saving the data. One workaround I saw a user suggest was to just keep using Google's API, but every time you make the query, store the data in your own DB as well (I only need address and name and latitude and longitude) so eventually, you'd have what you need in a sense. However I also want to have something like a simple rating system for each place like Yelp, but Google (and all other places like MapBox, Here Maps, etc) states something along the lines of "info from their API should not be stored or cached for more than 24hrs" but it's very broad and not specific.
So what I was planning to do was, call the Google API, grab the 3 info I need (Address, Name, Lat/Lng), add more fields to store the rating, likes, whatever else the user will add. Then store it in my database, but that doesn't seem like a solution now.
So does anyone have any ideas or advice? Or know of a service where I can get the details of all the food places? And if possible, can anyone confirm that storing the Name, Address, Lat&Lng is a violation of their policy since in my eyes, it's public data, but something like the rating that Google provides, or the pictures that Google provides, now that's Google property.
For obtaining places you can use OpenStreetMap, e.g. using Overpass API. Since larger traffic can be expected you should run your own database(s) instead of using the public APIs.
However OSM doesn't contain ratings. So you have to combine this data with some other publicly available rating system.

How to get public data from Google plus

I have a project that involves having public data downloaded from Google plus, can you give me a reference on how I can download like 1 GB of any type of public data from Google plus?
The data can be posts or circles information. I've tried to work with developer tools but the far I got is downloading my own profile information but what I need is public data.
Thanks !
There is no truly "public" data on Google+.
Every stream is unique to a user.
Try viewing the site without logging in, and you'll see what I mean.
Since users have the ability to block other users from viewing even their "public" posts, before Google shows you a post they check to see if you're on the blocked list. For them to be able to do that, you have to be logged in.
Your best bet would be to create a dummy account and only look at your nearby stream or What's Hot.
Otherwise you'd need to circle users, and that would create the stream. G+ is not like twitter. There's no firehose to speak of.
To programmatically cull data, you would have to use their API, but even then their HTTP API limits you to 20 results per search and you have to provide a query.
You could get up to 100 results per user if you picked individuals and got their userids, but again there's not a programmatic way to get a bulk dump.
You could randomly select users by using an activity search for a dictionary entry, and then seed that into the activity listing api... something like (in pure pseudocode)
for Random word in dictionary
group = userids from GET https://www.googleapis.com/plus/v1/activities?query=[word]
for userid in group
GET https://www.googleapis.com/plus/v1/people/[userid]/activities/collection/public
Actual code would of course depend on the language.

DISQUS: Is it possible to get a particular user's posts in a given forum?

I am running a website, whose community is powered by Disqus. I would like to create user profile pages, where the page would display the particular user's most recent activity, but only for my particular site (forum, in Disqus' terminology).
I ran through the entire API documentation, but I could not find a way that would allow me to filter by both user, and forum. I would be able to grab either the entire list of posts for a given forum, or the one from a particular user.
In every API call, there is a mysterious query paramater, where I tried to plug a series of filters, but none of them worked.
Is there something that I could be missing?
It's not that obvious, but you can use the query param as a filter for users. Try something like this:
https://disqus.com/api/3.0/forums/listPosts.json?forum={SHORTNAME}&query=user:{USERNAME}&api_key={YOUR_API_KEY}

Spine.js model - resource creation before id is updated

Guys,
I have two models, Notebook and Note. Note belongs to a notebook and notebook has many notes.
In my application I have a very common 3-columns view, 1st col lists notebooks, and 2nd col lists the notes corresponding to the selected notebook, and the 3rd col contains a form of the currently selected note.
In Spine, I didn't use the relation module. Every time the user selects a notebook, I call get /notebooks/:id/notes to fetch the corresponding notes of the selected notebook and render the note list, and when user click to create a new note, I will create a Spine object of note model with the current selected notebook_id and call save(). It works fine with the existing notebooks.
But there's a problem when a user creates a new notebook. If user click to create a new note inside this new notebook, before the notebook create ajax finishes, I don't have the actually notebook id from the database. So I think I have to wait for the notebook create ajax call back, before then I will block the user from clicking to create a new note.
But from Spine documentation, Alex said: Waiting for a server response goes against the whole concept of an asynchronous user interface.
So, what's the correct way to do this? Am I doing it right?
Thanks a lot.
In some cases it is way more complicated to not wait for a server response. It is up to you to decide when the non-blocking UI is worth the extra development effort and code complexity. In this case it shouldn't be terribly hard to trigger updating the reference ids on notes when the id on the notebook is updated, however it sounds like you wouldn't want to allow attempts to persist the note before that happens. That is doable without a blocking UI though.