Giter Club home page Giter Club logo

arcs's Introduction

Arcs

Cloud Build Status AppVeyor Build status arcs-live

Our mission is to create an open platform for smart and ubiquitous computing, where users have sovereignty over their data and its use.

A hosted version of Arcs is available at https://live.arcs.dev.

TypeDoc generated documentation is available for Arcs Runtime.

To develop with Arcs, please follow our Contributing Guide and tutorials.

Questions? Please join our Mailing list.

Subprojects

Subcomponents have more detailed descriptions. Particularly the extensions also have individual installation steps.

Chrome Extension

See extension.

Android Developer Tools

See DevToolsNG.

Chrome Developer Tools Extension

See devtools.

arcs's People

Contributors

aliceletitia avatar alxmrs avatar arcs-c3po avatar bayesianmind avatar bgogul avatar brad4d avatar cromwellian avatar csilvestrini avatar cypher1 avatar daviddrysdale avatar dfreedm avatar dstoc avatar galganif avatar ianull avatar jblebrun avatar lindner avatar mariakleiner avatar mykmartin avatar noelutz avatar piotrswigon avatar ragavsachdeva avatar raulverag avatar seefeldb avatar shans avatar shaper avatar sheimlich avatar sherry-pra avatar smalls avatar yuangu-google avatar yuinchien avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

arcs's Issues

Plumb returning event data from DOM context

Instead of sending only the handler name back, plumb the ports to handle an event(let) object, which contains the handler name and the target node's value (property) and key value. Most input elements use value for user-entered data, and key will be private data. For now, encode keys into the rendering stream (maybe attribute arc-key or data-arc-key), although if this is a sanitization issue, we can map key data to internally-generated ids for rendering.

See also #92

Dynamic loads from browser environment need to be asynchronous

The use of sync XHR in browser-loader triggers a browser warning as sync XHR is deprecated (and bad practice in any event). Using eval in the browser environment is also bad practice, and in particular makes the particle code invisible to the DevTools (maybe fixable via sourceMaps, but IMO better to fix the root cause).

Using sync XHR to load code that is then evald is double-plus ungood (6d7e5e8#diff-3063f0d93f4e10ec263645618f5aca81R75).

The best practice methods for loading code are all asynchronous and the current code expects to be able to loadParticle synchronously which IIUC means we need plumbing changes before modifying browser-loader.js.

Additionally, I think it's likely Particles will want to be able to load dependencies (code libraries, subclasses) dynamically.

Provided-slot view not verified

Particle may declare it its manifest that the slot that it provides should be used for a particular view.
However, it is not verify, and a Particle that doesn't have this view in its connections gets rendered
(example in arcs-hello-world project)

missing references in particle manifest files don't result in errors

A particle declaration like this:

particle MergeBodiesOfWater in 'MergeBodiesOfWater.js'
  ShowBodyOfWater(in [BodyOfWater] in0, in [BodyOfWater] in1, out [BodyOfWater] merged)
  affordance dom
  description `Merge 2 input bodies of water ${arg0} and ${arg1}`

Won't work - the particle names don't match in the 2 declarations (MergeBodiesOfWater != ShowBodiesOfWater), and the arguments in the description won't resolve ( (in0,in1) != (arg0,argv1) ).

If possible, we should give the user load-time errors that this particle definition won't work with as much detail as possible so they can fix it easily.

We may also want to think about removing the need to state the particle name twice as it's an opportunity to make mistakes like this.

get products from current open tabs into the arc

We want to pass information from the extension (for instance, a list of tabs) via a manifest into an Arc.

The first use case we're targeting is to get a list of open product tabs (amazon.com links, for instance) and pass those as products into gift demo arc.

Factor SlotManager to move DOM-specific knowledge into Slot subclasses

Motivation: IIUC, a slot represents a display channel for a particle.

Already in the implementation we support a slot which renders to DOM and another which renders to mock (headless) DOM. Other slots may represent rendering to other contexts (other devices, or specific content areas [e.g. suggestions]).

Another issue should tackle the dependency-injection question (how SlotManager knows which kind of Slot to provide).

Tweak strategy-explorer and suggestions-element so they can be reused in multiple contexts

The strategy-explorer and suggestions-element modules provide Web Components that we want to use in applications and environments beyond runtime/browser/demo*.

There are a few minor bits that need tweaking to support flexible reuse (mostly, removal of require and some minor factoring).

I mentioned in a team meeting that this code was forked in arcs-cdn. I think this was misunderstood to mean the design of functionality was altered, but really the changes were only to enable reuse as above. With this issue resolved, the code in this repo can be The Source of Truth and the arcs-cdn will contain only build artifacts.

SlotManager to remove pending request, if particle released the slot

If Particle releases slot before it was provided (Slot Manager still has it in pending requests), SlotManager will not remove the pending request, so it will remain pending.
(I'm not quite sure what will happen when SlotManager finally provides the slot to a particle that is not pending, but the Particle's slotPromise is not delete either on release)

We need to rationalize how arcs register that they have data available

Currently mini-particles set themselves up s.t. if their defining function returns a generator then an extraData flag will signal to the arc::tick function that the generator should be allowed to produce more data even if the input arguments haven't changed.

However, this doesn't work for particles without inputs as they would never be invoked in order to produce a generator. Further, it doesn't work for full particles. We need to make all of this work properly.

Rename Suggestinator to Strategizer

or Strateginator? :)
This is to avoid confusion between "suggestions" that currently mean suggested plans and "suggestions" that are currently named "descriptions". After this is done, description-generator should be renamed to suggestions-generator (or suggestinator?)

Shane, Doug, please, let me know when is a good time to do the renaming to not interfere with any of your work in progress, thanks!

Remove type information, etc. from inner PEC

get rid of all the complicated type stuff on the particle side. This can happen entirely on the arc side, I think, leaving particles just working with bundles of data. Probably should defer until after we work out what Entities look like.

document APIs that we (internally as a team) depend on

We should have a methods that cross boundaries within our team (e.g., kernel<->CDN) documented in the source, and those docs should include a comment that any API changes should have a github issue raised up for them. We hope this'll help us to coordinate these changes between the all of the repos.

These may include:

Arc (non '_'-prefix methods - constructor, instantiate, createView, commit)
SlotComposer (constructor)
Planner (constructor)
Manifest (load, _imports, _recipes)

This also probably means a bit of refactoring. I see some straight references from https://polymerlabs.github.io/arcs-cdn/v0.03/utils.js to Manifest._imports and Manifest._recipes, and it'll be clearer if we don't have direct references to '_' prefix members.

I may also be missing some. I pulled this list from:

https://polymerlabs.github.io/arcs-cdn/v0.03/utils.js
view-source:https://polymerlabs.github.io/arcs-cdn/v0.03/playground/playground.html

See #301 for a more end-user-dev doc bug (where we target docs at particle authors). There's some overlap to be aware of.

Improve descriptions

Earlier we had the Product List "from your browsing context" and "Claire wishlist" descriptions for views.
We lost them in transition to new manifest and right now everything is just "product list".
It should be improved by either putting description directly into the view, or using tags or else..

specify type of affordance in slot

Particles can be rendered as different kinds of affordances, e.g. as a "summary" or "link" instead of "full" (?). For example a recommender might expose a sources slot and request link|summary affordances, disallowing the entire sources to be rendered inline.

Particles can also transition from one affordance to another, which might involve changing slots. E.g. a linked source might on tapping the link want to render itself as full, but do so in root slot it requests at that time (in a large screen, maybe both would be visible at the same time, hence two slots) or just need a larger size and change its affordance to editor (TBD: Can the recommender disallow that? What happens then?).

This should probably be strict matching (i.e. no automatic mapping of labels) and thus a small, slowly growing vocabulary.

Whitelist some set of elements to be used via VDOM, incl. paper-*

incl. determining the subset of events we want to support.

requires research on whether just a subset of what gets sent in an event is enough or whether more work is needed (e.g. is the value of interest in an input field already a parameter to the event handler, so we can just subset the parameters to sanitize?)

remote provided slot not resolved for particle in a separate recipe

arcs-hello-world
If splitting the particles to separate recipes:
recipe
Greet
recipe
PersonalGreet

where
particle Greet
consume root
provide personalGreeting
particle PersonalGreet
consume personalGreeting

after Greet was instantiated, a slot should become available for Personal Greet, but it is not getting resolved by the map-remote-slots strategy.

Multiple inheritance missing from shema.org imports

import 'https://schema.org/Restaurant'

Fails with the following error:

jsonldToManifest.js:30
Uncaught (in promise) TypeError: Cannot read property 'subclasses' of undefined
at Function.convert (jsonldToManifest.js:30)
at fetch.then.then.data (loader.js:58)
at

It looks like multiple inheritance is missing.

for (var clazz of Object.values(classes)) {
if (clazz['rdfs:subClassOf'] !== undefined) {
var superclass = clazz['rdfs:subClassOf']['@id'];
classes[superclass].subclasses.push(clazz);
clazz.superclass = classes[superclass];
}
}

clazz['rdfs:subClassOf'] may be an array if there are multiple sub-classes.

See: https://noelutz.users.x20web.corp.google.com/www/schema.org.png

Context editor

Let's us modify what the planner uses to create suggestions.

Each has a checkbox so we can turn it on and off.

They are all manifests (static files) or arc urls (which storage shim would load), but could be grouped as:

  • "particle index", point to a firebase that lists all "published" particles
  • in-progress particles, point to manifests on e.g. glitch instances for particles in development
  • data, manifests that contained serialized (static) arcs:
    • about the user
    • from other users shared with the user, e.g. wishlist (maybe grouped by "other user"?)
    • from locations
  • context from extension
  • inline text box for anything else

Probably need a way to prioritize some of those, meaning suggestions need to use at least one view from that source. Let's tackle this after the the above is set up.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.