Mithun P. Acharya, Chris Parnin, Nicholas A. Kraft, Aldo Dagnino, Xiao Qu
Code Drones logo credits: Vaishnavi Murthy
Best Visions Paper at ICSE 2016, Runner Up
codedrones.org
Make software artifacts intelligent �… and let artifacts drive their own improvement/change
2
“Code Drones” in one slide!
Classes�Bug Reports�Test Cases�Requirement Docs�...
3
What is the problem?
4
Problem
(Automated) Software Engineering requires significant “human in the loop” and is thus REACTIVE
5
Problem
(Automated) Software Engineering requires significant “human in the loop” and is thus REACTIVE
6
Library/API Migration
Patching Vulnerabilities
Code Reuse
Refactoring
...
Reactive approach to these lead to significant technical debt
What is Code Drones?
7
Code Drones is a new abstraction towards PROACTIVE Software Engineering ...
8
… led by intelligent software artifacts, thus reducing “human in the loop”
9
Humans
Intelligent Software Artifacts
Problem: Revisited with Code Drones
(Automated) Software Engineering requires significant “human in the loop” and is thus REACTIVE
… abstraction towards PROACTIVE Software Engineering
10
reduce with intelligent/proactive software artifacts
PROACTIVE
11
Examples of “Code Drones”-powered intelligent/proactive software artifacts
Problem: Bug Management is critical for software projects
12
Proactive/Intelligent Bugs with Code Drones
Bugs contact the right developers that can fix them
13
proactive/intelligent bug report!
Problem: Reuse opportunities are seldom known let alone be leveraged
14
Code Reuse
Proactive/Intelligent Components/Libraries with Code Drones
Components/Libraries communicate to developers (and implement) reuse opportunities in real time
15
Hi! dll from Sweden! Based on your context, here’s how you can use me!
Problem: Refactoring always put off until next release!
16
Proactive/Intelligent classes with Code Drones
Classes auto refactor for performance and security
17
Classes will have access to TEST/PRODUCTION �build/runtime data
Proactive/Intelligent classes with Code Drones
With CodeLens, tests, bugs, work items, ... already communicate with classes
For simple cases, a class will autofix itself based on the test result/data
18
CodeLens
Problem: Library migration and fixing vulnerabilities a big headache
19
Library/API Migration
Patching Vulnerabilities
Proactive/Intelligent Clients and Libraries with Code Drones
Classes auto upgrade libraries, run all test cases, and submit an auto pull request
20
Proactive/Intelligent Clients and Libraries with Code Drones
Classes auto upgrade libraries, run all test cases, and submit an auto pull request
21
API Monkey�github.com/alt-code/APIMonkey
22
“Product Hunt” submissions
Startup!�
input
output
Includes:
Landing page on github�Project Management�...
@dailystartupbot
Now, that’s proactive!
What is the key idea behind Code Drones?
23
Make software artifacts intelligent �… and let artifacts drive their own improvement/change
24
Classes�Bug Reports�Test Cases�Requirement Docs�...
… and let software artifacts go social with developers
25
Intelligent and social software artifacts are called Code Drones.
Thus we have class drones, bug drones, library drones, requirement drones, test drones, ....
26
Do I have to change my artifacts to make them intelligent?
27
28
How do I make artifacts intelligent then?
29
Put an intelligent agent behind every software artifact
30
How do I make the agent intelligent?
31
32
How do I make my artifacts social?
33
Promote code to first class citizens in github like developers
34
35
Developer-Artifact social network
Codebook graph that connects Pam and Dave via artifacts
Like Pam and Dave, Code Drones powered software artifacts will be intelligent too!
PAM
DAVE
ARTIFACTS
Proactive/Intelligent Clients and Libraries with Code Drones
Classes auto upgrade libraries, run all test cases, and submit an auto pull request
36
API Monkey�github.com/alt-code/APIMonkey
37
First Code Drones assisted auto pull request that proactively:
a) upgrades about two dozen libraries AND
b) confirms that all 357 test cases pass after upgrade!
Pull request submitted by: API Monkey
38
I REVIEWED!
PULL REQUEST MERGED
39
40
357 tests passed after upgrade
41
Failed upgrading redis beyond 2.2.3
42
Why upgrading redis beyond 2.2.3 failed?
43
Library upgrades went fine!
Testing efforts saved
How do I make the agent intelligent?
44
Intelligence implemented as microservices in the cloud
45
Software Artifact
modify
subscribe
46
Traditional�SE
Search
Social
Reasoning
Automated Software Engineering
Concolic Execution
Search-Based SE Techniques
Regression Testing�Semantic Similarity�...�
MICROSERVICES
47
Traditional�SE
Search
Reasoning
Visual Studio Developer Assistant�Social network search, Boa
Web search, stackoverflow�
Social
Drones search. Not humans!
Automated Software Engineering
Concolic Execution
Search-Based SE Techniques
Regression Testing�Semantic Similarity�...�
MICROSERVICES
48
Traditional�SE
Search
Reasoning
Social APIs
Social
Automated Software Engineering
Concolic Execution
Search-Based SE Techniques
Regression Testing�Semantic Similarity�...�
Visual Studio Developer Assistant�Social network search, Boa
Web search, stackoverflow�
MICROSERVICES
49
Traditional�SE
Search
Reasoning
Social APIs
Simple If This Then That (IFTTT) APIs
…
Complex Watson/Siri-like APIs
Social
Automated Software Engineering
Concolic Execution
Search-Based SE Techniques
Regression Testing�Semantic Similarity�...�
Visual Studio Developer Assistant�Social network search, Boa
Web search, stackoverflow�
MICROSERVICES
Who will implement Code Drones agents and Microservices?
50
51
Business model: Microservices can be sold for a premium!�… and let the best microservice offering win!
52
The CROWD in crowdsourcing will be both humans and drones
drones
humans
53
COGNITIVE Business, Law, Oncology, Cooking, IoT, Finance, Sports, Insurance, Vehicles, � Healthcare, Transportation, Entertainment, Education, Retail, ...
With Code Drones, we have have taken the first step towards �Cognitive Software Engineering�
54
Software Artifact
modify
subscribe
55
Code Drones
Proactive Software Engineering
Microintelligence�Cognitive Software Engineering
Multiagent Systems for Software Engineering�Human Bot Interaction
PERSPECTIVES
focus of this talk
56
Key idea: Make software artifacts intelligent
Code Drones
codedrones.org
57
codedrones.org
Proactive bug/issue management
Instant Reuse
Auto refactoring
Auto API migration
API Monkey
Code Drones
@dailystartupbot
Auto startup generator
Key idea: Make software artifacts intelligent
58
codedrones.org
Proactive bug/issue management
Instant Reuse
Auto refactoring
Auto API migration
@dailystartupbot
API Monkey
Auto startup generator
Immersive IDEs
No more editing code by hand!�Talk to your classes!
Code Drones
Key idea: Make software artifacts intelligent
59
codedrones.org
Proactive bug/issue management
Instant Reuse
Auto refactoring
Auto API migration
API Monkey
Auto startup generator
Immersive IDEs
No more editing code by hand!�Talk to your classes!
Social patching
Social Software Estimation
Distributed Verification and Testing
Applications to Mining Software Repositories
Code Drones
@dailystartupbot
Key idea: Make software artifacts intelligent
60
codedrones.org
61
Best review comment ever!
One of the reviewers of our paper:
… Classes might even write recommendations on other classes and "unfriend" bad classes. I suppose a class might also brag about its performance, and why not, a class might also post selfies of its private methods, which some of its friends (classes) might "like"! ...
62
63
64
Software Artifacts as Friends
Humanizing Software Artifacts
Software Artifact Choreographed Software Engineering (SACSE)
Code Drones
65